A + B Problem - waiting...'s Blog

A + B Problem

waiting... posted @ 2009年3月01日 18:51 in C/C++ with tags a+b problem 求和 , 1523 阅读

 

  1. //题目描述:
  2. //A + B Problem
  3. //
  4. //输入:
  5. //多组测试数据,第一行有两个小于1e9的整数,
  6. //对这两个数求和,最后当EOF标志的时候结束。
  7. //
  8. //输出:
  9. //对这两个数求和的结果
  10. //
  11. //样例输入:
  12. //2 3
  13. //1 9
  14. //
  15. //样例输出:
  16. //5
  17. //10
  18.  
  19. #include <iostream>
  20. using namespace std;
  21.  
  22. int main()
  23. {
  24.         int a, b;
  25.         while (cin >> a && cin >> b)
  26.                 cout << a + b << endl;
  27.         return 0;
  28. }
Avatar_small
celebrity heights 说:
2023年6月21日 14:18

This is very helpful for me, and the people who are looking for info about celeb height wiki>


登录 *


loading captcha image...
(输入验证码)
or Ctrl+Enter
Host by is-Programmer.com | Power by Chito 1.3.3 beta | © 2007 LinuxGem | Design by Matthew "Agent Spork" McGee