Borderou de evaluare (job #3313747)
| Utilizator | Data | 6 octombrie 2025 14:58:37 | |
|---|---|---|---|
| Problema | Cuburi3 | Status | done |
| Runda | Arhiva de probleme | Compilator | cpp-64 | Vezi sursa |
| Scor | 0 | ||
Raport evaluator
Eroare de compilare:
main.cpp:11:34: error: 'int index' redeclared as different kind of entity
11 | int ant[4005], dp[4005], ma = 0, index, sum = 0;
| ^~~~~
In file included from /usr/include/string.h:462,
from /usr/include/c++/12.2.1/cstring:42,
from /usr/include/c++/12.2.1/x86_64-pc-linux-gnu/bits/stdc++.h:48,
from main.cpp:1:
/usr/include/strings.h:61:1: note: previous declaration 'const char* index(const char*, int)'
61 | index (const char *__s, int __c) __THROW
| ^~~~~
main.cpp: In function 'bool cmp(date, date)':
main.cpp:14:44: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
14 | return i.lat < j.lat || i.lat == j.lat && i.g < j.g;
| ~~~~~~~~~~~~~~~^~~~~~~~~~~~
main.cpp: In function 'int main()':
main.cpp:51:21: error: overloaded function with no contextual type information
51 | index = i;
| ^
main.cpp:59:18: error: invalid operands of types '<unresolved overloaded function type>' and 'int' to binary 'operator!='
59 | while (index != -1) {
| ~~~~~~^~~~~
main.cpp:60:25: error: invalid types 'date [4005][<unresolved overloaded function type>]' for array subscript
60 | ans.push_back (a[index].id);
| ^
main.cpp:61:17: error: invalid types 'date [4005][<unresolved overloaded function type>]' for array subscript
61 | sum += a[index].lat;
| ^
main.cpp:62:20: error: invalid types 'int [4005][<unresolved overloaded function type>]' for array subscript
62 | index = ant[index];
| ^
main.cpp:66:20: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
66 | for (int i=0; i<ans.size(); ++i)
| ~^~~~~~~~~~~
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !
