Problem addition
User weiqi
Submission Time 2024-06-18 10:38:14
Score 0
Max Time N/A
Max Memory N/A

Compile Error

addition.cpp: In function ‘int main()’:
addition.cpp:5:2: error: ‘cin’ was not declared in this scope
5 | cin >> a >> b;
| ^~~
addition.cpp:1:1: note: ‘std::cin’ is defined in header ‘<iostream>’; did you forget to ‘#include <iostream>’?
+++ |+#include <iostream>
1 | using namespace std;
addition.cpp:8:2: error: ‘cout’ was not declared in this scope
8 | cout << c;
| ^~~~
addition.cpp:8:2: note: ‘std::cout’ is defined in header ‘<iostream>’; did you forget to ‘#include <iostream>’?
addition.cpp:9:10: error: expected ‘;’ before ‘}’ token
9 | return 0
| ^
| ;
10 | }
| ~