#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 | #64750361 | Utilizator | |
| Fișier | gradmax.cpp | Dimensiune | 801 B |
| Data încărcării | 27 Mai 2026, 18:09 | Scor/rezultat | Eroare de compilare |
gradmax.cpp: In function ‘int main()’: gradmax.cpp:32:21: warning: comparison of integer expressions of different signedness: ‘std::set<int>::size_type’ {aka ‘long unsigned int’} and ‘int’ [-Wsign-compare] 32 | if(p.size() == M) | ~~~~~~~~~^~~~ gradmax.cpp:38:21: warning: comparison of integer expressions of different signedness: ‘std::set<int>::size_type’ {aka ‘long unsigned int’} and ‘int’ [-Wsign-compare] 38 | if(p.size() == M) | ~~~~~~~~~^~~~ gradmax.cpp:39:21: error: ‘auot’ was not declared in this scope; did you mean ‘auto’? 39 | for(auot &q : p) | ^~~~ | auto gradmax.cpp:39:29: error: found ‘:’ in nested-name-specifier, expected ‘::’ 39 | for(auot &q : p) | ^ | :: gradmax.cpp:39:27: error: ‘q’ has not been declared 39 | for(auot &q : p) | ^ gradmax.cpp:42:14: error: could not convert ‘fin.std::basic_ifstream<char>::close()’ from ‘void’ to ‘bool’ 42 | fin.close(); | ~~~~~~~~~^~ | | | void gradmax.cpp:43:17: error: expected ‘)’ before ‘;’ token 43 | fout.close(); | ^ | ) gradmax.cpp:39:20: note: to match this ‘(’ 39 | for(auot &q : p) | ^
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ă.