6
What is the output of the following program?
int i = 10;
do { i++; } while (i < 5);
Console.WriteLine(i);DiscussEasy
Loading subject content…
Loading practice questions…
What is the output of the following program?
int i = 10;
do { i++; } while (i < 5);
Console.WriteLine(i);What is the output of the following program?
string grade = "B";
switch (grade)
{
case "A": Console.Write("Top"); break;
case "B":
case "C": Console.Write("Pass"); break;
default: Console.Write("Fail"); break;
}What is the output of the following program?
for (int i = 1; i <= 5; i++)
{
if (i == 3) continue;
Console.Write(i);
}What is the output of the following program?
int x = 15;
if (x % 3 == 0 && x % 5 == 0) Console.Write("FizzBuzz");
else if (x % 3 == 0) Console.Write("Fizz");
else Console.Write(x);