#1462
Gasti
Problema | Gasti | Operații I/O |
gasti.in /gasti.out
|
---|---|---|---|
Limita timp | 0.5 secunde | Limita memorie |
Total: 16 MB
/
Stivă 4 MB
|
Id soluție | #30312064 | Utilizator | |
Fișier | gasti.cpp | Dimensiune | 1.22 KB |
Data încărcării | 14 Iulie 2021, 16:10 | Scor / rezultat | Eroare de compilare |
gasti.cpp:9:47: error: conflicting declaration 'int f [100001]' int n , m , x , y , v[100001] , cnt , f[100001] , maxi , maxi2 , fmaxi , fmaxi2; ^ gasti.cpp:5:10: error: 'f' has a previous declaration as 'std::ifstream f' ifstream f("gasti.in"); ^ gasti.cpp: In function 'int main()': gasti.cpp:38:10: error: no match for 'operator[]' (operand types are 'std::ifstream {aka std::basic_ifstream<char>}' and 'int') f[v[i]]++; ^ gasti.cpp:41:13: error: no match for 'operator[]' (operand types are 'std::ifstream {aka std::basic_ifstream<char>}' and 'int') if(f[i] > maxi) maxi = f[i]; ^ gasti.cpp:41:33: error: no match for 'operator[]' (operand types are 'std::ifstream {aka std::basic_ifstream<char>}' and 'int') if(f[i] > maxi) maxi = f[i]; ^ gasti.cpp:44:13: error: no match for 'operator[]' (operand types are 'std::ifstream {aka std::basic_ifstream<char>}' and 'int') if(f[i] == maxi) fmaxi++; ^ gasti.cpp:53:17: error: no match for 'operator[]' (operand types are 'std::ifstream {aka std::basic_ifstream<char>}' and 'int') if(f[i] > maxi2 && f[i] != maxi) maxi2 = f[i]; ^ gasti.cpp:53:33: error: no match for 'operator[]' (operand types are 'std::ifstream {aka std::basic_ifstream<char>}' and 'int') if(f[i] > maxi2 && f[i] != maxi) maxi2 = f[i]; ^ gasti.cpp:53:55: error: no match for 'operator[]' (operand types are 'std::ifstream {aka std::basic_ifstream<char>}' and 'int') if(f[i] > maxi2 && f[i] != maxi) maxi2 = f[i]; ^ gasti.cpp:55:17: error: no match for 'operator[]' (operand types are 'std::ifstream {aka std::basic_ifstream<char>}' and 'int') if(f[i] == maxi2 && f[i] != maxi) fmaxi2++; ^ gasti.cpp:55:34: error: no match for 'operator[]' (operand types are 'std::ifstream {aka std::basic_ifstream<char>}' and 'int') if(f[i] == maxi2 && f[i] != maxi) fmaxi2++; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Gasti face parte din prima categorie. Soluția propusă de tine va fi evaluată astfel:
Suma punctajelor acordate pe testele utilizate pentru verificare este 100. Astfel, soluția ta poate obține cel mult 100 de puncte, caz în care se poate considera corectă.