#3976
Se dă numărul natural nenul n. Să se determine produsul primelor n numere impare.
| Problema | ProdImpare | Operații I/O |
tastatură/ecran
|
|---|---|---|---|
| Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
| Id soluție | #64769707 | Utilizator | |
| Fișier | prodimpare.cpp | Dimensiune | 211 B |
| Data încărcării | 28 Mai 2026, 23:05 | Scor/rezultat | 50 puncte |
prodimpare.cpp: In function ‘int main()’: prodimpare.cpp:9:8: warning: init-statement in selection statements only available with ‘-std=c++17’ or ‘-std=gnu++17’ [-Wc++17-extensions] 9 | if(1<=n<=15;n!=0) | ^ prodimpare.cpp:9:12: warning: comparison of constant ‘15’ with boolean expression is always true [-Wbool-compare] 9 | if(1<=n<=15;n!=0) | ~~~~^~~~ prodimpare.cpp:9:9: warning: comparisons like ‘X<=Y<=Z’ do not have their mathematical meaning [-Wparentheses] 9 | if(1<=n<=15;n!=0) | ~^~~ prodimpare.cpp:9:12: warning: statement has no effect [-Wunused-value] 9 | if(1<=n<=15;n!=0) | ~~~~^~~~
| Test | Timp | Mesaj evaluare | Scor posibil | Scor obținut | ||
|---|---|---|---|---|---|---|
| 1 | 0.001 secunde | OK. | 10 | 10 | ||
| 2 | 0.001 secunde | OK. | 10 | 10 | ||
| 3 | 0.001 secunde | OK. | 10 | 10 | ||
| 4 | 0.001 secunde | OK. | 10 | 10 | ||
| 5 | 0.001 secunde | OK. | 10 | 10 | ||
| 6 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 7 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 8 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 9 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| 10 | 0.001 secunde | Raspuns gresit. | 10 | 0 | ||
| Punctaj total | 50 | |||||
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema ProdImpare 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ă.