using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace flag4
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("请输入李四的评审等级A-E");
string input = Console.ReadLine();
decimal salary = 5000;
bool flag = false;
switch (input)
{
case "A":
salary += 500;
break;
case "B":
salary+= 200;
break;
case "C":
salary = 5000;
break;
case "D":
salary -= 200;
break;
case "E":
salary -= 500;
break;
default:
{
Console.WriteLine("你输入的有问题");
flag = true;
break;
}
}
if(flag==false)
{
Console.WriteLine("李四的工资为"+salary);
}
Console.ReadKey();
}
}
}
|