using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
int i = 1;
while (i < 10)
{
Console.WriteLine(i);
i++;
if(i == 3)
{
break; // break是指终止循环
}
Console.WriteLine("我在这儿");
}
Console.ReadKey();
}
}
}
循环中断——break
最新推荐文章于 2023-12-12 23:47:07 发布