Borderou de evaluare (job #3329849)
| Utilizator | Data | 16 decembrie 2025 10:58:07 | |
|---|---|---|---|
| Problema | Potrivirea sirurilor | Status | done |
| Runda | Arhiva educationala | Compilator | cpp-64 | Vezi sursa |
| Scor | 0 | ||
Raport evaluator
Eroare de compilare:
main.cpp: In function 'void frontiera(std::string*, std::string*, int)':
main.cpp:12:16: error: expected unqualified-id before 'int'
12 | int q = 0, int k;
| ^~~
main.cpp:15:15: error: 'k' was not declared in this scope
15 | if (p[k + 1] == p[q])
| ^
main.cpp:19:16: error: 'k' was not declared in this scope
19 | f[q] = k;
| ^
main.cpp: In function 'int main()':
main.cpp:28:16: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'const char*'
28 | n = strlen(p);
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}
In file included from /usr/include/c++/12.2.1/cstring:42,
from main.cpp:2:
/usr/include/string.h:407:35: note: initializing argument 1 of 'size_t strlen(const char*)'
407 | extern size_t strlen (const char *__s)
| ~~~~~~~~~~~~^~~
main.cpp:29:16: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'const char*'
29 | m = strlen(t);
| ^
| |
| std::string {aka std::__cxx11::basic_string<char>}
/usr/include/string.h:407:35: note: initializing argument 1 of 'size_t strlen(const char*)'
407 | extern size_t strlen (const char *__s)
| ~~~~~~~~~~~~^~~
main.cpp:30:18: warning: left operand of comma operator has no effect [-Wunused-value]
30 | for (i = 1;i <= n,i++)
| ~~^~~~
main.cpp:30:26: error: expected ';' before ')' token
30 | for (i = 1;i <= n,i++)
| ^
| ;
main.cpp:24:15: warning: unused variable 'j' [-Wunused-variable]
24 | int n, i, j, m, q = 0, nr_g = 0;
| ^
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !
