第六节课三个作业
2018-11-07 本文已影响0人
dcy1
![](https://img.haomeiwen.com/i14498955/b160d25d05c040a9.jpg)
Console.WriteLine("本金");
string str_p=Console.ReadLine();
int p=Convert.ToInt32(str_p);
Console.WriteLine("年利率");
string str_r=Console.ReadLine();
int r=Convert.ToInt32(str_r);
Console.WriteLine("年数");
string str_n=Console.ReadLine();
int n=Convert.ToInt32(str_n);
Console.WriteLine("总金");
int a=p*(1+r)*n;
Console.WriteLine (a); Console.ReadKey();