编程实现计算鸡蛋个数的问题
2016-07-02 13:55:58 访问(1920) 赞(0) 踩(0)

using System;
using System.Collections.Generic;
using System.Text;
namespace SlowX.CalcEgg
{
class Program
{
static void Main(string[] args)
{
int theResult = 0;
while (true)
{
theResult += 9;
if (theResult % 5 != 4)
continue;
if (theResult % 6 != 3)
continue;
if (theResult % 7 != 5)
continue;
// 因为8是2和4的倍数,所以不用计算 //
if (theResult % 8 != 1)
continue;
break;
}
Console.WriteLine(theResult);
}
}
}
标签:
编程实现计算鸡蛋个数的问题 


上一条:
下一条:
相关评论
发表评论