| Problem | tourist_noi |
|---|---|
| User | ilovepythonandhatecplusplus |
| Submission Time | 2026-02-20 16:22:38 |
| Score | 0 |
| Max Time | N/A |
| Max Memory | N/A |
Owl Get a Life
tourist_noi.cpp: In function ‘int main()’:
tourist_noi.cpp:2:65: error: ‘cin’ was not declared in this scope
2 | using namespace std;int main() {long long n,x,y,a;long long s=0;cin>>n>>x>>y;for (int i=0;i<n;i++){cin>>a;if (a*x<y){s+=a*x;}else{s+=y;}}cout<<s;}
| ^~~
tourist_noi.cpp:1:1: note: ‘std::cin’ is defined in header ‘<iostream>’; did you forget to ‘#include <iostream>’?
+++ |+#include <iostream>
1 |
tourist_noi.cpp:2:138: error: ‘cout’ was not declared in this scope
2 | using namespace std;int main() {long long n,x,y,a;long long s=0;cin>>n>>x>>y;for (int i=0;i<n;i++){cin>>a;if (a*x<y){s+=a*x;}else{s+=y;}}cout<<s;}
| ^~~~
tourist_noi.cpp: