#1264
StatisticiOrdine
Se dau n
numere naturale. Să se afișeze al k
-lea cel mai mic element din șir.
Problema | StatisticiOrdine | Operații I/O |
statisticiordine.in /statisticiordine.out
|
---|---|---|---|
Limita timp | 1.5 secunde | Limita memorie |
Total: 16 MB
/
Stivă 1 MB
|
Id soluție | #53909690 | Utilizator | |
Fișier | statisticiordine.cpp | Dimensiune | 981 B |
Data încărcării | 14 Noiembrie 2024, 14:56 | Scor / rezultat | Eroare de compilare |
statisticiordine.cpp:9:26: error: size of array 'v' is too large unsigned int v[4000000005]; ^ statisticiordine.cpp: In function 'int main()': statisticiordine.cpp:19:13: error: 'v' was not declared in this scope fout << v[k]; ^ statisticiordine.cpp: In function 'void citire()': statisticiordine.cpp:26:25: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for(int i = 1; i <= n; i++) ^ statisticiordine.cpp:27:16: error: 'v' was not declared in this scope fin >> v[i]; ^ statisticiordine.cpp: In function 'int partitie(int, int)': statisticiordine.cpp:43:26: error: 'v' was not declared in this scope unsigned int pivot = v[dr], nr = st-1, aux; ^ statisticiordine.cpp:47:13: error: 'nr' was not declared in this scope nr++; ^ statisticiordine.cpp:48:13: error: 'aux' was not declared in this scope aux = v[i]; ^ statisticiordine.cpp:53:5: error: 'aux' was not declared in this scope aux = v[nr+1]; ^ statisticiordine.cpp:53:13: error: 'nr' was not declared in this scope aux = v[nr+1]; ^ statisticiordine.cpp:58:1: warning: control reaches end of non-void function [-Wreturn-type] } ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema StatisticiOrdine 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ă.