0_0_39290971_17248.cpp: In function 'int main()':
0_0_39290971_17248.cpp:4:11: error: 'cin' was not declared in this scope
4 | while(cin >> T && T){
| ^~~
0_0_39290971_17248.cpp:1:1: note: 'std::cin' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
+++ |+#include <iostream>
1 | using namespace std;
0_0_39290971_17248.cpp:8:13: error: 'scanf' was not declared in this scope
8 | scanf("%d", &num);
| ^~~~~
0_0_39290971_17248.cpp:11:9: error: 'cout' was not declared in this scope
11 | cout << res << endl;
| ^~~~
0_0_39290971_17248.cpp:11:9: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
0_0_39290971_17248.cpp:11:24: error: 'endl' was not declared in this scope
11 | cout << res << endl;
| ^~~~
0_0_39290971_17248.cpp:1:1: note: 'std::endl' is defined in header '<ostream>'; did you forget to '#include <ostream>'?
+++ |+#include <ostream>
1 | using namespace std;
|