Borderou de evaluare (job #951424)
Utilizator | Data | 20 mai 2013 16:06:08 | |
---|---|---|---|
Problema | Cpal | Status | done |
Runda | Arhiva Monthly | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp:8:9: error: conflicting declaration ‘int f [10]’
int f[10], x, nri;
^
user.cpp:5:10: error: ‘f’ has a previous declaration as ‘std::ifstream f’
ifstream f("cpal.in");
^
user.cpp: In function ‘int main()’:
user.cpp:17:22: error: no match for ‘operator[]’ (operand types are ‘std::ifstream {aka std::basic_ifstream<char>}’ and ‘int’)
f>>x; ++f[x];
^
user.cpp:21:16: error: no match for ‘operator[]’ (operand types are ‘std::ifstream {aka std::basic_ifstream<char>}’ and ‘int’)
if (f[i]!=0)
^
user.cpp:23:29: error: no match for ‘operator[]’ (operand types are ‘std::ifstream {aka std::basic_ifstream<char>}’ and ‘int’)
ok=true; if (f[i]%2==1) ++nri;
^
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !