#437
Conex
Se dă lista muchiilor unui graf neorientat. Să se verifice dacă graful este sau nu conex.
Problema | Conex | Operații I/O |
conex.in /conex.out
|
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #15814315 | Utilizator | |
Fișier | conex.cpp | Dimensiune | 835 B |
Data încărcării | 14 Mai 2019, 11:31 | Scor / rezultat | Eroare de compilare |
conex.cpp: In function 'void citire()': conex.cpp:8:9: error: 'n' was not declared in this scope f>> n >> m; ^ conex.cpp:8:14: error: 'm' was not declared in this scope f>> n >> m; ^ conex.cpp:11:13: error: 'x' was not declared in this scope f>> x >> y; ^ conex.cpp:11:18: error: 'y' was not declared in this scope f>> x >> y; ^ conex.cpp:12:9: error: 'a' was not declared in this scope a[x][y]=a[y][x]=1; ^ conex.cpp: At global scope: conex.cpp:15:50: error: conflicting declaration 'int g' int a[101][101], x,y,m,n,xc,yc,viz[101],sol[101],g=1,c[101],end; ^ conex.cpp:5:10: error: 'g' has a previous declaration as 'std::ofstream g' ofstream g("conex.out"); ^ conex.cpp: In function 'void DF(int)': conex.cpp:20:8: error: no match for 'operator[]' (operand types are 'int [101]' and 'std::ofstream {aka std::basic_ofstream<char>}') sol[g]=q; ^ conex.cpp:25:18: error: no 'operator++(int)' declared for postfix '++' [-fpermissive] g++; ^ conex.cpp: In function 'int main()': conex.cpp:32:11: warning: statement is a reference, not call, to function 'citire' [-Waddress] citire; ^ conex.cpp:32:11: warning: statement has no effect [-Wunused-value]
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Conex 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ă.