Problem | greeting |
---|---|
User | Longcx |
Submission Time | 2023-11-08 11:02:59 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
greeting.cpp: In function ‘int main()’:
greeting.cpp:4:2: error: ‘string’ was not declared in this scope
4 | string x; getline(cin, x);
| ^~~~~~
greeting.cpp:1:1: note: ‘std::string’ is defined in header ‘<string>’; did you forget to ‘#include <string>’?
+++ |+#include <string>
1 | using namespace std;
greeting.cpp:4:20: error: ‘cin’ was not declared in this scope
4 | string x; getline(cin, x);
| ^~~
greeting.cpp:1:1: note: ‘std::cin’ is defined in header ‘<iostream>’; did you forget to ‘#include <iostream>’?
+++ |+#include <iostream>
1 | using namespace std;
greeting.cpp:4:25: error: ‘x’ was not declared in this scope
4 | string x; getline(cin, x);
| ^
greeting.cpp:4:12: error: ‘getline’ was not declared in this scope
4 | string x; getline(cin, x);
| ^~~~~~~
greeting.cpp:5:2: error: ‘