#4204
| Problema | esteArbore | Operații I/O |
estearbore.in/estearbore.out
|
|---|---|---|---|
| Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
| Id soluție | #64397447 | Utilizator | |
| Fișier | estearbore.cpp | Dimensiune | 562 B |
| Data încărcării | 05 Mai 2026, 09:51 | Scor/rezultat | Eroare de compilare |
estearbore.cpp:5:1: error: expected ‘,’ or ‘;’ before ‘ofstream’ 5 | ofstream fout("estearbore.out") | ^~~~~~~~ estearbore.cpp: In function ‘void dfs(int)’: estearbore.cpp:9:5: error: ‘v’ was not declared in this scope 9 | v[x]=1; | ^ estearbore.cpp:10:18: warning: range-based ‘for’ loops with initializer only available with ‘-std=c++20’ or ‘-std=gnu++20’ [-Wc++20-extensions] 10 | for(int i=1; i<=n: i++) | ^ estearbore.cpp:10:22: error: found ‘:’ in nested-name-specifier, expected ‘::’ 10 | for(int i=1; i<=n: i++) | ^ | :: estearbore.cpp:10:21: error: ‘n’ has not been declared 10 | for(int i=1; i<=n: i++) | ^ estearbore.cpp:14:1: error: expected primary-expression before ‘}’ token 14 | } | ^ estearbore.cpp:12:20: error: expected ‘;’ before ‘}’ token 12 | dfs(i); | ^ | ; 13 | 14 | } | ~ estearbore.cpp:14:1: error: expected primary-expression before ‘}’ token 14 | } | ^ estearbore.cpp:12:20: error: expected ‘)’ before ‘}’ token 12 | dfs(i); | ^ | ) 13 | 14 | } | ~ estearbore.cpp:10:8: note: to match this ‘(’ 10 | for(int i=1; i<=n: i++) | ^ estearbore.cpp:14:1: error: expected primary-expression before ‘}’ token 14 | } | ^ estearbore.cpp: In function ‘int main()’: estearbore.cpp:17:10: error: ‘n’ was not declared in this scope 17 | fin>>n; | ^ estearbore.cpp:18:16: error: ‘x’ was not declared in this scope 18 | while(fin>>x>>y) | ^ estearbore.cpp:18:19: error: ‘y’ was not declared in this scope 18 | while(fin>>x>>y) | ^ estearbore.cpp:20:9: error: ‘a’ was not declared in this scope 20 | a[x][y]==a[y][x]=1; | ^ estearbore.cpp:23:8: error: ‘m’ was not declared in this scope; did you mean ‘tm’? 23 | if(m!=n-1) { | ^ | tm estearbore.cpp:24:9: error: ‘fout’ was not declared in this scope 24 | fout<< "NU"; | ^~~~ estearbore.cpp:30:8: error: ‘v’ was not declared in this scope 30 | if(v[i]==0) | ^ estearbore.cpp:31:2: error: ‘g’ was not declared in this scope 31 | {g | ^ estearbore.cpp:35:1: error: ‘fout’ was not declared in this scope 35 | fout<<"DA"; | ^~~~
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema esteArbore 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ă.