What will be the output of the following C# code?
static void Main(string[] args)
{
int i = 0;
while (i++ != 0) ;
Console.WriteLine(i);
Console.ReadLine();
}
static void Main(string[] args)
{
int i = 0;
while (i++ != 0) ;
Console.WriteLine(i);
Console.ReadLine();
}A. -127 to +127
B. 0 to 127
C. 1
D. Infinite loop condition
Answer: Option C

Join The Discussion