#1652
RF
Se dă un graf orientat în care arcele au asociate costuri (numere naturale nenule). Să se determine câte arce (x,y)
din graf au costul egal cu costul drumului de cost minim de la x
la y
.
Problema | RF | Operații I/O | tastatură/ecran |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #8641657 | Utilizator | |
Fișier | rf.cpp | Dimensiune | 655 B |
Data încărcării | 05 Martie 2018, 13:16 | Scor / rezultat | Eroare de compilare |
rf.cpp: In function 'int descomp_drum()': rf.cpp:6:1: error: 'ok' was not declared in this scope ok = 0; ^ rf.cpp:7:1: error: 'k' was not declared in this scope k = 1; ^ rf.cpp:8:12: error: 'n' was not declared in this scope while(k <= n && ok != 0){ ^ rf.cpp:9:8: error: 'a' was not declared in this scope if(a[i][j] == a[i][k] + a[k][j]){ ^ rf.cpp:9:10: error: 'i' was not declared in this scope if(a[i][j] == a[i][k] + a[k][j]){ ^ rf.cpp:9:13: error: 'j' was not declared in this scope if(a[i][j] == a[i][k] + a[k][j]){ ^ rf.cpp:17:13: error: 'j' was not declared in this scope cout << j; ^ rf.cpp:18:1: warning: no return statement in function returning non-void [-Wreturn-type] } ^ rf.cpp: In function 'int roy_floyd()': rf.cpp:29:1: warning: no return statement in function returning non-void [-Wreturn-type] } ^ rf.cpp: In function 'int main()': rf.cpp:32:1: error: 'f' was not declared in this scope f >> n; ^ rf.cpp:32:6: error: 'n' was not declared in this scope f >> n; ^ rf.cpp:33:5: error: 'i' was not declared in this scope for(i = 1; i<= n; i++) ^ rf.cpp:35:6: error: 'a' was not declared in this scope f >> a >> b; ^ rf.cpp:35:11: error: 'b' was not declared in this scope f >> a >> b; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema RF 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ă.