Multiple Choice Question

Quiz Guidelines

 

QID: 
165
Question: 

Which of the following code snippets will compile without any errors?
(Assume that the statement int x = 0; exists prior to the statements below.)

Select 3 options

A. while (false) { x=3; }
B. if (false) { x=3; }
C. do{ x = 3; } while(false);
D. for( int i = 0; i< 0; i++) x = 3;

Q&A Set: