
C# Questions On For, While And If Else Statements
Quiz by Akzat Kauyssova
Feel free to use or edit a copy
includes Teacher and Student dashboards
Measure skillsfrom any curriculum
Measure skills
from any curriculum
Tag the questions with any skills you have. Your dashboard will track each student's mastery of each skill.
With a free account, teachers can
- edit the questions
- save a copy for later
- start a class game
- automatically assign follow-up activities based on students’ scores
- assign as homework
- share a link with colleagues
- print as a bubble sheet
10 questions
Show answers
- Q1Which of the C# loops is not a pretest loop?while loopfor loopdo while looploop20s
- Q2The break command is used to exit a loop.FalseTrueno answerBoth of them=)20s
- Q3Which of the followings is not a nested loop?for(i=0;i<10;i++) Console.Write("i={0}",i); for(j=1;j<i+2;j++) Console.Write("j={0}",j);Console.Write("j={0}",j);for(i=0;i<10;i++) while(j%2!=0){ Console.Write("{0}\t{1}", j, j++);}for(i=0;i<10;i++) Console.Write("i={0}",i);for(i=0;i<10;i++) for(j=1;j<i+2;j++)30s
- Q4Which of the following is not a logical operator in C# language?&&&!=||10s
- Q5The purpose of using a loop is toRepeat operation(s) many timesmake decisionRepeat operation(s) three timesRepeat operation(s) one time20s
- Q6Which of the following is not a comparison operator in C# language?=>==<=10s
- Q7Which of the following statements about the while loop is not true?Testing condition is made before each iteration.The while loop is a posttest loop.The while loop statement must terminate with a semi-colon.20s
- Q8There are two different ways to implement multi selections in C# language. They areswitch and caseif...else and switch caseif...else and switch caseelse-if and case20s
- Q9What Will Be The Output Of The Following Code Snippet:0 1 2 3 4 51 2 3 4 5 6 7 8 9 100 1 2 3 4 5 60 1 2 3 445s
- Q10What Will Be The Output Of The Following Code Snippet:4 3 2 1 02 3 4 13 2 4 14 3 2 145s