Q. Which of the following special symbol allowed in a variable?
A. * (asterisk)
B. | (pipeline)
C. - (hyphen)
D. _ (underscore)
Q.How would you round off a value from 1.66 to 2.0?
A. ceil(1.66)
A. 0, 1, 2
A. * (asterisk)
B. | (pipeline)
C. - (hyphen)
D. _ (underscore)
Q.How would you round off a value from 1.66 to 2.0?
A. ceil(1.66)
B. floor(1.66)
C. roundup(1.66)
C. roundup(1.66)
D. roundto(1.66)
Q.Which of the definition is correct?
A. int length;
Q.Which of the definition is correct?
A. int length;
B. char int;
C. int long;
C. int long;
D. float double;
Q. What is the output of the program given below ?
Q. What is the output of the program given below ?
#include
int main()
{
enum status { pass, fail, atkt};
enum status stud1, stud2, stud3;
stud1 = pass;
stud2 = atkt; stud3 = fail;
printf("%d, %d, %d\n", stud1, stud2, stud3);
return 0;
}
A. 0, 1, 2
B. 1, 2, 3
C. 0, 2, 1
C. 0, 2, 1
D. 1, 3, 2
Q. C is a?
Q. C is a?
(b) low level language
(c) high level language with some low level features.
(d) low level language with some high level features.
Q. What will happen if in a C program you assign a value to an array element whose subscript exceeds the size of array?
(a. The element will be set to 0.
(b. The compiler would report an error.
(c. The program may crash if some important data gets overwritten.
(d. The array size would appropriately grow.
(c) high level language with some low level features.
(d) low level language with some high level features.
Q. What will happen if in a C program you assign a value to an array element whose subscript exceeds the size of array?
(a. The element will be set to 0.
(b. The compiler would report an error.
(c. The program may crash if some important data gets overwritten.
(d. The array size would appropriately grow.
No comments:
Post a Comment