Problem generosity
User Ant1234567890
Submission Time 2025-06-11 18:53:46
Score 0
Max Time N/A
Max Memory N/A

Compile Error

generosity.cpp: In function ‘int main()’:
generosity.cpp:4:2: error: ‘cin’ was not declared in this scope; did you mean ‘std::cin’?
4 | cin>>x:
| ^~~
| std::cin
In file included from generosity.cpp:1:
/usr/include/c++/9/iostream:60:18: note: ‘std::cin’ declared here
60 | extern istream cin; /// Linked to standard input
| ^~~
generosity.cpp:4:8: error: found ‘:’ in nested-name-specifier, expected ‘::’
4 | cin>>x:
| ^
| ::
generosity.cpp:4:7: error: ‘x’ is not a class, namespace, or enumeration
4 | cin>>x:
| ^