下面的程序计算了一个循环的迭代次数,并且在循环终止时打印这个计数值。那么,它打印的是什么呢?
class InTheLoop
{
const int END = int.MaxValue;
const int START = END - 100;
static void Main()
{
int count = 0;
for (int i = START; i <= END; i++)
count++;
System.Console.WriteLine(count);
}
}
C#解惑总目录
class InTheLoop
{
const int END = int.MaxValue;
const int START = END - 100;
static void Main()
{
int count = 0;
for (int i = START; i <= END; i++)
count++;
System.Console.WriteLine(count);
}
}
C#解惑总目录