神灯系统2020—10.25
发表时间:2020-10-25
发布人:葵宇科技
浏览次数:42
神灯系统C#语言实现
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApplication1
{
class Class1
{
public void sd() {
Console.WriteLine("欢迎进入神灯系统!");
Console.WriteLine("中文服务请按“1”\t英文服务请按“2”");
while(true){
int a = int.Parse(Console.ReadLine());
switch(a){
case 1:{
Console.WriteLine("中文服务");
Console.WriteLine("1.祈祷");
Console.WriteLine("2.诅咒");
Console.WriteLine("3.实现愿望");
Console.WriteLine("4.还愿");
Console.WriteLine("5.高考分数查询");
int c = int.Parse(Console.ReadLine());
if (c == 1)
{
Console.WriteLine("祈祷");
}
else if(c==2){
Console.WriteLine("诅咒");
}else if(c==3){
Console.WriteLine("实现愿望");
Console.WriteLine("1.延年益寿");
Console.WriteLine("2.盛世美颜");
Console.WriteLine("3.强身健体");
Console.WriteLine("4.升官发财");
Console.WriteLine("5.找到爱情");
Console.WriteLine("8、 人工服务");
int b = int.Parse(Console.ReadLine());
if (b == 1) {
Console.WriteLine("1.延年益寿");
}else if(b==2){
Console.WriteLine("2.盛世美颜");
}else if(b==3){
Console.WriteLine("3.强身健体");
}else if(b==4){
Console.WriteLine("4.升官发财");
}else if(b==5){
Console.WriteLine("5.找到爱情");
}
else if (b == 8)
{
Console.WriteLine("8.人工服务");
}
else {
Console.WriteLine("输入错误!");
}
}else if (c == 4){
Console.WriteLine("还愿");
}
else if (c == 5)
{
Console.WriteLine("高考分数查询");
}
else {
Console.WriteLine("输入错误!");
}
break;
}
case 2: {
Console.WriteLine("英文服务");
break;
}
}
}
}
}
}