50 CÂU HỎI
Which of the following is the correct usage of condition operators used in C?
A. a>b? c = 20 : c = 21;
B. a>b? c = 20;
C. max = a>b? a>c?a:c:b>c?b:c;
D. return (a>b)?(a:b);
The expression of the right hand side of || operators does not get evaluated if the left hand side determines the outcome.
A. True
B. False
Which of the following correctly shows the hierarchy of arithmetic operator in C?
A. / + * –
B. * – / +
C. + – / *
D. / * + –
Which of the following is the correct order of evaluation for the below expression? z = x + y * z / 4 % 2 – 1;
A. * / % + – =
B. = * / % + –
C. / * % – + =
D. * % / – + =
What will be the output of the program?
A. 1 1 1 1
B. 1 0 0 1
C. 1 0 1 1
D. Other
What will be the output of the program?
A. 1 0 1
B. 1 1 1
C. 0 0 0
D. 0 1 0
What will be the output of the program?
A. z = 0
B. z = 1
C. z = 4
D. z = 3
Every operators has an Associativity
A. Yes
B. No
What will be the output of the program?
A. 4 2 -1 1
B. 4 3 0 1
C. 3 2 -1 1
What is output of the program?
A. 4 3 0 0
B. 3 3 0 1
C. 4 2 0 0
D. None of these
Are the following two statement same?
A. Yes
B. No
What will be the output of the program?
A. 6
B. 3
C. 12
D. Complier error
What will be output of the program?
A. 0 4 1
B. 1 4 1
C. 4 4 1
D. None of these
What will be output of the program?
A. 4 4
B. 3 4
C. 2 2
D. 2 3
What will be output of the program?
A. c = 1
B. c = 29
C. c = 10
D. c = 19
What will be output of the program?
A. 4 3 2
B. 4 3 3
C. 2 3 2
D. 2 3 3
What will be output of the program?
A. 20
B. 30
C. 40
D. 10
What is output of the program?
A. 4
B. 3
C. Complier error
D. None of above
What will be output of the program?
A. 3, 0, 0,
B. 3, 3, 3,
C. 3, garbage, garbage
D. Another
What value is returned by function func()?
A. 5
B. 0
C. Exception
D. Another
What will be output when you will execute following c code?
A. mmmm aaaa nnnn
B. mmm aaa nnn
C. mmmm aaa nnn
D. Another
What will be output when you will execute following c code?
A. AAAAAABCDEF
B. AAAAAABCDE
C. ABCDEF
D. Another
What gets printed?
A. 3
B. 4
C. 5
D. 6
What is output?
A. Hello
B. Nothing
C. Complier Error
D. Run time error
What is output?
A. 012
B. Run time error
C. 3
D. 2
What is output?
A. Complie time error
B. Infinite Loop
C. Nothing
What is output?
A. In for loop
B. After loop
C. Complie error
What is output?
A. True
B. False
C. Complie Error
D. Another
What is output ?
A. 5, 5
B. 10, 10
C. Syntax error
What is output?
A. a = 5,b = 5
B. a = 4,b = 4
C. a = 5,b = 0
D. Another
What is output ?
A. Hello
B. Hello is printed 3 times
C. Hello is prined 4 times
D. Hello is printed 5 times
What is output ?
A. Hello
B. Hello is printed 3 times
C. Hello is prined 4 times
D. Hello is printed 5 times
What is output?
A. 1 2 3
B. 0 1 2 3
C. 0 1 2
What is output ?
A. 12345
B. 123456
C. 6
D. 1234
What is output?
A. 99 99 99
B. Complier Error
C. 1
How many times will “vncoding” is printed on screen?
A. 10
B. 11
C. Infinite
What is output?
A. 1 3
B. 1 2
C. Không in ra kí tự nào
What is output?
A. Start End Start End
B. Start Start Start
C. Start Start Start Start
What is output of the following code?
A. 1 2 3 4 5 6 7 8 9
B. 3 4 5 6 7 8 9
C. 4 5 6 7 8 9
D. 4 5 6 7 8 9 10
What is output?
A. Infinite loop
B. 35
C. 38
D. 39
What is output?
A. 6, 5, 4, 3, 2, 1,
B. 6, 5, 4, 3, 2, 1, 0,
C. Complier Error
D. Infinite loop
What is output?
A. 0
B. -1
C. -2
D. -3
What is output?
A. 0
B. 2
C. 3
D. -4
What is output?
A. print i and j from 0 till 4
B. print i and j from 0 till 5
C. print i from 0 to 4, print j from 0 to 5
D. Complier Error
What gets printed?
A. 5
B. 6
C. 7
D. Another
What gets printed?
A. Value of x is 0
B. Value of x is not 0
C. Error
What gets printed?
A. 14,18,
B. 16,20,
C. 16,21
What gets printed ?
A. -1
B. 0
C. 1
D. Complier error
What is output ?
A. Hello
B. Hi
C. Complier error
What is output?
A. x=0 y=1
B. x=0 y=0
C. Error syntax