fork download
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main(void)
  6. {
  7. int A, B;
  8.  
  9. while (1)
  10. {
  11. cin >> A >> B;
  12.  
  13. if (A == 0 && B == 0)
  14. break;
  15.  
  16. cout << A + B << endl;
  17. }
  18. return 0;
  19. }
Success #stdin #stdout 0s 4796KB
stdin
1 1
2 3
3 4
9 8
5 2
0 0
stdout
2
5
7
17
7