Professional Documents
Culture Documents
1) 3*x*x+3*(4x+6) 2) 3*x*x+3(4x+6)
3) 3*x*x+3(4*x+6) 4) 3*x*x+3*(4*x+6)
1) 1 2) 2 3) 5 4) Compiler dependent
1) %= 2) != 3) ^= 4) &=
10. How to store value of x in y?
1) ^ 2) ~ 3) sizeof 4) $
1) ! 2) ~ 3) - 4) - -
1) ^ 2) >> 3) ~ 4) &&
1) / 2) % 3) ++ 4) !
1) + k 2) ++ k 3) +++ k 4) ++++ k
17. Which operator does not check 2nd condition if 1st condition is false?
1) -> 2) .* 3) != 4) +=
1) 5 2) Compilation error
3) 32767 4) Runtime error
1) 5 2) Compilation error
3) 32767 4) Runtime error
1) 18 2) 2 3) 14 4) Compilation error
1) 1 3 3 2) 2 3 3 3) 2 4 3 4) 1 4 3
27. void main( )
{ int x=2;
float f1=1.0, f2=2.0, sum;
sum=x*f1+f2/x+f1*f2;
printf(“%f ”, sum);
}
1) 5.000000 2) 6.000000
3) 1.500000 4) Compilation error
1) 10 2) 5 3) 0 4) 1
30. void main( ).
{ int i=2, j=3, k=0, m=0 ;
float a=1, b=2;
k=i/j *k;
m=j/i*j;
a=i*/j*j;
b=i*j/k;
printf(“%d %d %f %f ”, k, m, a, b);
}
1) 8 2) 4 3) 6 4) Compilation Error
1) 3 2) 2 3) -1 4) Error:Lvalue required
1) c 99 2) C 99 3) 3 51 4) 3 garbage
1) 10 9 10 2) 10 10 10 3) 9 11 10 4) 10 10 11
1) 10 9 8 2) 8 8 8 3) 9 8 7 4) 7 8 9
1) 180 10 2) 5 40 3) 1 80 4) 80 1
1) 49 2) 42 3) 36 4) 30
1) 0 1 1 2) 1 1 1 3) 0 1 0 4) none
1) 3 -3 1 2) 3 4 0 3) 3 132 0 4) -3 132 1
1) 8 2) 30 3) 128 4) 64