C Programming Questions & Answers: part5



Software Programming : C Programming QUESTIONS AND ANSWERS :: part5 : 11 to 15

Following Software Programming language Entrance Multiple choice objective type questions and answers will help you in Software Programming 2024 examinations :

11.What is the output of the following piece of program? int value = 11; while( --value+1 ); printf( �Count down is : %d�, value);

Count down is : 0
Count down is : -1
Count down is : 1
Syntax error
Run time error.

12.What will be printed if the following code is executed? void main( ) { int x = 0; for( ; ; ) { if( x++ == 4 ) break; continue; } printf( �x = %d�, x); }

x = 0
x = 5
x = 4
x = 1
Error, because break and continue can not appear in one for loop.

13.What is the output of the following piece of code in Turbo C? void main( ) { int a=20, b=35; a = b++ + a++; b = ++b + ++a; printf( � %d, %d�, a, b); }

57, 94
56, 94
58, 94
57, 93
55, 55.

14.int array[3][2][2] = { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12}; What value does array[2][1][0] in the above array contain?

5
7
9
11
15.

More C Programming QUESTIONS AND ANSWERS available in next pages

    Health is the greatest gift, contentment is the greatest wealth -Buddha
A real entrepreneur is somebody who has no safety net underneath them. Henry Kravis