摘要: Console.WriteLine("请输入身份证号"); string s = Console.ReadLine(); string jqn = s.Substring(6, 4); string jqy = s.Substr... 阅读全文
posted @ 2015-09-14 15:42 软件工程开发 阅读(860) 评论(0) 推荐(0) 编辑
摘要: //一对幼兔,1个月后长成小兔, //再过一个月长成成兔并且生下一对幼兔, //问,24个月后,有多少对兔子。 while (true) { int m, ct, xt, yt, ... 阅读全文
posted @ 2015-09-14 10:44 软件工程开发 阅读(274) 评论(0) 推荐(0) 编辑
摘要: /异常语句 /* try { int a = int.Parse(Console.ReadLine()); } catch (Exception ex) ... 阅读全文
posted @ 2015-09-14 10:19 软件工程开发 阅读(125) 评论(0) 推荐(0) 编辑
摘要: int sum = 0; Console.Write("请输入数字:"); int shu = int.Parse(Console.ReadLine()); for (int i = 1; i <= shu; i++)//从1开始遍... 阅读全文
posted @ 2015-09-14 10:06 软件工程开发 阅读(161) 评论(0) 推荐(0) 编辑
摘要: int renying = 0; int dnying = 0; for (int i = 1; i = 2) { Console.WriteLine("三局两胜人赢了"); } ... 阅读全文
posted @ 2015-09-14 09:12 软件工程开发 阅读(371) 评论(0) 推荐(0) 编辑
摘要: 方法一: while (true) { Console.Write("输入年:"); int year = int.Parse(Console.ReadLine()); Console.... 阅读全文
posted @ 2015-09-14 08:59 软件工程开发 阅读(351) 评论(0) 推荐(0) 编辑