[問題] 兩數相加
開發平台(Platform): (Ex: VC++, GCC, Linux, ...)
orwell dev-c++ 5.5.2 64-bit portable
額外使用到的函數庫(Library Used): (Ex: OpenGL, ...)
none
問題(Question):
兩數相加
餵入的資料(Input):
3 2
10 20
預期的正確結果(Expected Output):
5
30
錯誤結果(Wrong Output):
輸入:
3 8
1(隨便一個數字都行)
輸出:
11
如圖所示:
http://i.imgur.com/jALUt7x.jpg

程式碼(Code):(請善用置底文網頁, 記得排版)
#include<stdio.h>
#include<stdlib.h>
int main(void){
int a,b,c;
scanf("%d %d\n",&a,&b);
c=a+b;
printf("%d\n",c);
system("PAUSE");
return 0;
}
補充說明(Supplement):
已在版面上 /兩數 /相加沒有發現到類似文章
google有看到類似問題的解 但看不太懂 囧
希望有強者可指出問題點 謝謝
--
╭◥██◣╮ ╭═════╮ ╭ ███═◢█ ══════════╮
║ █▌ ╰══╯◢▌ ★ ╰═════╯ █ █ ◤▕▁◤ ◥ ║
║ █▌ ◢█◣ ██◣ ◢ ◢◢◣ ◢█◣ ◥██◣ █ ◤ ▕  ̄ξ▄ ║
║ █▌ █▌ █▌█ █ █◤ █▌█ ▄ █ █ ◣  ̄﹀ ║
║ ◥██◣◥█◤ ◥▌◤ ◤ █ ◥█◤ ◥██◤◢██◣ ◣ ︱﹨ ║
╰═══════════════════════════════ theanswer3 ╯
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 1.34.251.152
→
11/02 16:20, , 1F
11/02 16:20, 1F
→
11/02 16:21, , 2F
11/02 16:21, 2F
→
11/02 16:21, , 3F
11/02 16:21, 3F
※ 編輯: a1982213 來自: 1.34.251.152 (11/02 16:25)
→
11/02 16:26, , 4F
11/02 16:26, 4F
推
11/02 16:29, , 5F
11/02 16:29, 5F
→
11/02 16:31, , 6F
11/02 16:31, 6F
推
11/02 21:09, , 7F
11/02 21:09, 7F