What will be the output of the C#.NET code snippet given below? int num = 1, z = 5; if (!(num <= 0)) Console.WriteLine( ++num + z++ + " " + ++z ); else Console.WriteLine( --num + z-- + " " + --z );

- Online Exam Test Papers | - MCQs[multiple choice questions and answers ] | - Mock Test Papers | - Practice Papers | - Sample Test Papers |

Question:
What will be the output of the C#.NET code snippet given below?

int num = 1, z = 5;

if (!(num <= 0))
    Console.WriteLine( ++num + z++ + " " + ++z ); 
else
    Console.WriteLine( --num + z-- + " " + --z ); 

1.5 6

2.6 5

3.6 6

4.7 7

Posted Date:-2021-02-25 10:28:15


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!