C Language MCQ’S : Operators and Expressions Set 2

16.
A static variable

A. cannot be initialized
B. is initialized once at the commencement of execution and cannot be changed at run time
C. retains its value throughout the file of the program
D. is same as an automatic variable but is placed at the head of a program

 

17.
The statement
# include < math.h>
is written at the top of a program to indicate

A. beginning of the program
B. beginning of the program
C. that certain information about mathematical library functions are to be included at the begnning of the program
D. none of these

 

18.
The declarations
typedef float hight [100];
height men, women;

A. define men and women as 100 element floating point arrays
B. define men and women as floating point variables
C. define height, men and women as floating point variables
D. are illegal

 

19.
In case of ordinary int variables

A. leftmost bit is reserved for sign
B. rightmost bit is reserved for sign
C. no bit is reserved for sign
D. none of these

 

20.
Consider the program fragment

j = 2;
while ((i % j) ! = 0)
j = j + 1;
if (j < i) printf (“%d”, j);

If i >= 2, then the value of j, will be printed only if

A. i is prime
B. j does not divide i
C. j is odd
D. i is not prime

 

Visitor Counter

0056739