#417
Se dă lista muchiilor unui graf neorientat. Să se afișeze vârfurile de grad maxim.
Problema | GradMax | Operații I/O |
![]() gradmax.in /gradmax.out
|
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #57241396 | Utilizator | |
Fișier | gradmax.cpp | Dimensiune | 745 B |
Data încărcării | 21 Martie 2025, 11:56 | Scor / rezultat | Eroare de compilare |
gradmax.cpp:3:1: error: 'ifstream' does not name a type ifstream in("gradmax.in") ^ gradmax.cpp: In function 'int main()': gradmax.cpp:11:5: error: 'in' was not declared in this scope in >> n; ^ gradmax.cpp:11:11: error: 'n' was not declared in this scope in >> n; ^ gradmax.cpp:12:17: error: 'x' was not declared in this scope while( n >> x >> y) { ^ gradmax.cpp:12:22: error: 'y' was not declared in this scope while( n >> x >> y) { ^ gradmax.cpp:13:9: error: 'a' was not declared in this scope a[x][y] = a[y][x] = 1; ^ gradmax.cpp:19:16: error: 'a' was not declared in this scope if(a[i][j]) v[i]++; ^ gradmax.cpp:19:25: error: 'v' was not declared in this scope if(a[i][j]) v[i]++; ^ gradmax.cpp:21:13: error: 'v' was not declared in this scope if (v[i] > nmax) ^ gradmax.cpp:21:20: error: 'nmax' was not declared in this scope if (v[i] > nmax) ^ gradmax.cpp:26:12: error: 'v' was not declared in this scope if(v[i]==nmax) ^ gradmax.cpp:26:18: error: 'nmax' was not declared in this scope if(v[i]==nmax) ^ gradmax.cpp:27:13: error: 'nr' was not declared in this scope nr++; ^ gradmax.cpp:29:5: error: 'out' was not declared in this scope out << nr << ' '; ^ gradmax.cpp:29:12: error: 'nr' was not declared in this scope out << nr << ' '; ^ gradmax.cpp:32:13: error: 'v' was not declared in this scope if (v[i]==nmax) ^ gradmax.cpp:32:19: error: 'nmax' was not declared in this scope if (v[i]==nmax) ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema GradMax 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ă.