#代码
int line = 0;
int sum = 0;
Console.WriteLine("1-100不能被7整除的数字为:");
for (int i = 1; i < 101; i++)
{
if (i % 7 == 0)
{
continue;
}
Console.Write("\t" + i);
sum += i;
line++;
if (line % 4 == 0)
{
Console.Write("\n");
}
}
Console.WriteLine("数字和为:{0}", sum);
Console.ReadKey();
网友评论