Sail E0 Webinar

MCQs

Total Questions : 209 | Page 5 of 21 pages
Question 41. Determine Output:#define prod(a,b) a*bvoid main(){ int x=3, y=4; printf("%d", prod(x+2, y-1));}
  1.    10
  2.    11
  3.    12
  4.    15
 Discuss Question
Answer: Option A. -> 10
Question 42. Determine Output:void main(){ int c[] = {2.8,3.4,4,6.7,5}; int j, *p=c, *q=c; for(j=0;j
  1.    2 3 4 6 5 2 3 4 6 5
  2.    2.8 3.4 4 6.7 5 2.8 3.4 4 6.7
  3.    2 2 2 2 2 2 3 4 6 5
  4.    2.8 2.8 2.8 2.8 2.8 2.8 3.4 4
 Discuss Question
Answer: Option C. -> 2 2 2 2 2 2 3 4 6 5
Question 43. Determine Output:void main(){ char *p; p="%dn"; p++; p++; printf(p-2, 300);}
  1.    300
  2.    Error
  3.    %d\n
  4.    None of These
 Discuss Question
Answer: Option A. -> 300
Question 44. Determine Output:void main(){ char p[]="%dn"; p[1] = 'c'; printf(p, 65);}
  1.    Error
  2.    A
  3.    c
  4.    65
 Discuss Question
Answer: Option B. -> A
Question 45. Determine Output:void main(){ int a[] = {10,20,30,40,50}, j, *p; for(j=0; j
  1.    10 20 30 40 50 Garbage Value
  2.    10 20 30 40 50 10 20 30 40 50
  3.    None of These
  4.    Error
 Discuss Question
Answer: Option D. -> Error
Question 46. Determine Output:#includevoid main(){ char s[]={'a','b','c','n','c','\0'}; char *p, *str, *str1; p=&s[3]; str=p; str1=s; printf("%c", ++*p + ++*str1-32);}
  1.    None of These
  2.    M
  3.    P
  4.    N
 Discuss Question
Answer: Option B. -> M
Question 47. Determine Output:void main(){ static char *s[] = {"black", "white", "yellow", "violet"}; char **ptr[] = {s+3, s+2, s+1, s}, ***p; p = ptr; ++p; printf("%s",*--*++p + 3); }
  1.    et
  2.    ck
  3.    ow
  4.    te
 Discuss Question
Answer: Option B. -> ck
Question 48. For 16-bit compiler allowable range for integer constants is ________?
  1.    -32767 to 32768
  2.    -3.4e38 to 3.4e38
  3.    -32768 to 32767
  4.    -32668 to 32667
 Discuss Question
Answer: Option C. -> -32768 to 32767
Question 49. Who is father of C Language?
  1.    Bjarne Stroustrup
  2.    F. Codd
  3.    James
  4.    Gosling
  5.    Dr.
  6.    Dennis Ritchie
 Discuss Question
Answer: Option F. -> Dennis Ritchie
Question 50. C Language developed at _________?
  1.    AT & T's Bell Laboratories of USA in 1972
  2.    Cambridge University in 1972
  3.    AT & T's Bell Laboratories of USA in 1970
  4.    Sun Microsystems in 1973
 Discuss Question
Answer: Option A. -> AT & T's Bell Laboratories of USA in 1972

Latest Videos

Latest Test Papers