**问题描述:**判断一个数是否为素数。
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threading.Tasks;namespace Test_01{class Program{public bool Caculate(int num){if (num == 1||num==0||num<0)return false;else{for (int i = 2; i <num; i++){if (num % i == 0)return false;}}return true;}static void Main(string[] args){int demo = int.Parse(Console.ReadLine());Program program = new Program();bool Mid = program.Caculate(demo);Console.WriteLine(\"输出结果为:\"+Mid );Console.ReadLine();}}}