Which of the following is the correct output for the C#.NET program given below?int i = 20 ; for( ; ; ) { Console.Write(i + " "); if (i >= -10) i -= 4; else break;

Question:
Which of the following is the correct output for the C#.NET program given below?int i = 20 ;
for( ; ; )
{
    Console.Write(i + " "); 
    if (i >= -10)
        i -= 4; 
    else 
        break;

1.20 16 12 84 0 -4 -8

2.20 16 12 8 4 0

3.20 16 12 8 4 0 -4 -8 -12

4.16 12 8 4 0

Posted Date:-2021-02-20 14:28:12


More MCQS Questions and answers

Search
R4R Team
R4Rin Top Tutorials are Core Java,Hibernate ,Spring,Sturts.The content on R4R.in website is done by expert team not only with the help of books but along with the strong professional knowledge in all context like coding,designing, marketing,etc!