Problem | ultimateifelse |
---|---|
User | Pandin |
Submission Time | 2024-06-18 10:51:26 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
ultimateifelse.cpp: In function ‘int main()’:
ultimateifelse.cpp:20:19: error: cannot convert ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘const char*’
20 | } else if (strlen(S) > 5) {
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}
In file included from /usr/include/c++/9/cstring:42,
from ultimateifelse.cpp:2:
/usr/include/string.h:385:35: note: initializing argument 1 of ‘size_t strlen(const char*)’
385 | extern size_t strlen (const char *__s)
| ~~~~~~~~~~~~^~~
ultimateifelse.cpp:22:19: error: cannot convert ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘const char*’
22 | } else if (strlen(S) == N) {
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}
In file included