您的位置:首页 > 编程语言 > C#

100-200之间的素数

2016-08-07 16:50 323 查看
using System;

using System.Collections.Generic;

using System.Linq;

using System.Text;

using System.Threading.Tasks;

namespace _100到200全部素数

{

    class Program

    {

        static void Main(string[] args)

        {

            for (int i = 100; i <= 200; i++)

            {

                if (i % 2 == 0 || i % 3 == 0 || i % 5 == 0 || i % 7 == 0)

                {

                    continue;

                }

                else

                {

                    Console.WriteLine(i);

                }

            }Console.ReadKey();

        }

    }

}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  c# 素数 100-200