討論串[問題] 數字被吃一位?
共 3 篇文章
首頁
上一頁
1
下一頁
尾頁

推噓0(0推 0噓 4→)留言4則,0人參與, 最新作者Fnd (勸君莫回首)時間14年前 (2009/10/05 22:24), 編輯資訊
1
0
0
內容預覽:
請問,我寫. static void Main(string[] args). {. int i, x, y;. while (Console.Read() != 0). {. x = int.Parse(Console.ReadLine());. Console.Write(x);. }. }.
(還有15個字)

推噓0(0推 0噓 0→)留言0則,0人參與, 最新作者kinwind時間14年前 (2009/10/05 23:53), 編輯資訊
0
0
0
內容預覽:
更正一下程式,其實我想得太多了. static void Main(string[] args). {. string x;. while ((x = Console.ReadLine()) != null). {. Console.WriteLine(x);. }. }. input : 1234

推噓1(1推 0噓 0→)留言1則,0人參與, 最新作者tarjan (Mr. Everything)時間14年前 (2009/10/06 14:58), 編輯資訊
0
0
0
內容預覽:
由原文看起來似乎是要限定第一個數字不能是0?. 如果是的話可以這樣作. static void Main(string[] args). {. string x;. int y;. while ((y=Console.Read()) != -1). {. x = Console.ReadLine()
首頁
上一頁
1
下一頁
尾頁