#1476
FSortare
C++
Să se scrie o funcție C++
care sortează crescător elementele unei liste simplu înlănţuite.
Problema | FSortare | Operații I/O | tastatură/ecran |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #13070186 | Utilizator | |
Fișier | fsortare.cpp | Dimensiune | 284 B |
Data încărcării | 05 Ianuarie 2019, 18:12 | Scor / rezultat | Eroare de compilare |
fsortare.cpp: In function 'void sortareCrescator(nod*&)': fsortare.cpp:33:15: error: no match for 'operator=' (operand types are 'nod' and 'nod*') for(j = i->urm; j; j = j->urm) ^ fsortare.cpp:33:15: note: candidates are: fsortare.cpp:3:8: note: nod& nod::operator=(const nod&) struct nod{ ^ fsortare.cpp:3:8: note: no known conversion for argument 1 from 'nod*' to 'const nod&' fsortare.cpp:3:8: note: nod& nod::operator=(nod&&) fsortare.cpp:3:8: note: no known conversion for argument 1 from 'nod*' to 'nod&&' fsortare.cpp:33:25: error: could not convert 'j' from 'nod' to 'bool' for(j = i->urm; j; j = j->urm) ^ fsortare.cpp:33:33: error: base operand of '->' has non-pointer type 'nod' for(j = i->urm; j; j = j->urm) ^ fsortare.cpp:34:28: error: base operand of '->' has non-pointer type 'nod' if(i->info >= j->info) ^ fsortare.cpp:37:20: error: base operand of '->' has non-pointer type 'nod' i->info = j->info; ^ fsortare.cpp:38:10: error: base operand of '->' has non-pointer type 'nod' j->info = data; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema FSortare face parte din a doua categorie. Pentru aceste probleme se folosește un program suport, furnizat de propunătorul problemei. 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ă.