fork download
  1. #include <iostream>
  2. #include <string>
  3. #include <sstream>
  4.  
  5. using namespace std;
  6. int main() {
  7. size_t testCount;
  8. cin >> testCount >> ws;
  9. if(testCount < 0 || testCount > 100) return 0;
  10. int input;
  11. while(testCount--) {
  12. string instr;
  13. getline(cin, instr);
  14. cout << instr << '\n';
  15. }
  16. return 0;
  17. }
Success #stdin #stdout 0s 3276KB
stdin
3
hello
world
foo
bar
stdout
hello
world
foo