Problem | abcs |
---|---|
User | ArianneLim |
Submission Time | 2024-08-03 15:03:25 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
abcs.cpp: In function ‘int main()’:
abcs.cpp:8:11: error: structured binding declaration cannot have type ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’}
8 | string[q];
| ^~~
abcs.cpp:8:11: note: type must be cv-qualified ‘auto’ or reference to cv-qualified ‘auto’
abcs.cpp:8:12: error: conflicting declaration ‘auto q’
8 | string[q];
| ^
abcs.cpp:7:9: note: previous declaration as ‘int q’
7 | int q; cin>>q;
| ^
abcs.cpp:8:14: error: expected initializer before ‘;’ token
8 | string[q];
| ^
abcs.cpp:11:19: error: expected primary-expression before ‘[’ token
11 | cin>>string[i];
| ^
abcs.cpp:17:19: error: expected primary-expression before ‘[’ token
17 | cin>>string[i];
| ^