Isn't the iostream library the first thing that is taught for C++ (it being necessary for Hello World)?
Quote:
McAwesome:/tmp $ cat test.cpp
#include <iostream>
int main(){
int num_inputs, num;
std::cin >> num_inputs;
for(int i=0; i < num_inputs; i++){
std::cin >> num;
std::cout << "lol: " << num << std::endl;
}
return 0;
}
McAwesome:/tmp $ g++ test.cpp
McAwesome:/tmp $ echo "7 3 4 6 4 5 7 5" | ./a.out
lol: 3
lol: 4
lol: 6
lol: 4
lol: 5
lol: 7
lol: 5