Problem addition
User Robotzfive
Submission Time 2025-05-18 17:46:30
Score 0
Max Time N/A
Max Memory N/A

Compile Error

addition.cpp: In function ‘int main()’:
addition.cpp:5:5: error: ‘cin’ was not declared in this scope; did you mean ‘std::cin’?
5 | cin >> a >> b;
| ^~~
| std::cin
In file included from addition.cpp:1:
/usr/include/c++/9/iostream:60:18: note: ‘std::cin’ declared here
60 | extern istream cin; /// Linked to standard input
| ^~~
addition.cpp:6:28: error: ‘endl’ was not declared in this scope; did you mean ‘std::endl’?
6 | std:: cout << a + b << endl;
| ^~~~
| std::endl
In file included from /usr/include/c++/9/iostream:39,
from addition.cpp:1:
/usr/include/c++/9/ostream:599:5: note: ‘std::endl’ declared here
599 | endl(basic_ostream<_CharT, _Traits>& __os)
| ^~~~