Advertisement
pascallius

fahr

Oct 12th, 2023
52
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.28 KB | None | 0 0
  1. void loop() {
  2.  
  3.     while (true) {
  4.         int i1, i2;
  5.         std::cin >> i1 >> i2;
  6.         std::cout << i1 + i2 << "\n";
  7.         int again;
  8.         std::cout << "Again? (0/1)\n";
  9.         std::cin >> again;
  10.         if (!(again == 1)) break;
  11.     }
  12. }
  13. int main() {
  14.   loop();
  15.  
  16. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement