#3063
Scrieți un program care citește un număr natural nenul n
și care afișează numele lunii calendaristice corespunzătoare numărului n
.
Problema | luna | Operații I/O |
![]() |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #38352488 | Utilizator | |
Fișier | luna.cpp | Dimensiune | 521 B |
Data încărcării | 07 Octombrie 2022, 19:54 | Scor / rezultat | 10 puncte |
luna.cpp: In function 'int main()': luna.cpp:9:12: warning: suggest parentheses around assignment used as truth value [-Wparentheses] if (n=1) cout<<"ianuarie"; ^ luna.cpp:10:17: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if (n=2) cout<<"februarie"; ^ luna.cpp:11:17: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if (n=3) cout<<"martie"; ^ luna.cpp:12:17: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if (n=4) cout<<"aprilie"; ^ luna.cpp:13:17: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if (n=5) cout<<"mai"; ^ luna.cpp:14:17: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if (n=6) cout<<"iunie"; ^ luna.cpp:15:17: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if (n=7) cout<<"iulie"; ^ luna.cpp:16:17: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if (n=8) cout<<"august"; ^ luna.cpp:17:17: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if (n=9) cout<<"setembrie"; ^ luna.cpp:18:18: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if (n=10) cout<<"octombrie"; ^ luna.cpp:19:18: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if (n=11) cout<<"noiembrie"; ^ luna.cpp:20:18: warning: suggest parentheses around assignment used as truth value [-Wparentheses] else if (n=12) cout<<"decembrie"; ^
Test | Timp | Mesaj evaluare | Scor posibil | Scor obținut | ||
---|---|---|---|---|---|---|
1 | 0 secunde | OK. | 10 | 10 | ||
2 | 0 secunde | Raspuns gresit. | 10 | 0 | ||
3 | 0 secunde | Raspuns gresit. | 5 | 0 | ||
4 | 0 secunde | Raspuns gresit. | 5 | 0 | ||
5 | 0 secunde | Raspuns gresit. | 10 | 0 | ||
6 | 0 secunde | Raspuns gresit. | 10 | 0 | ||
7 | 0 secunde | Raspuns gresit. | 10 | 0 | ||
8 | 0 secunde | Raspuns gresit. | 10 | 0 | ||
9 | 0 secunde | Raspuns gresit. | 10 | 0 | ||
10 | 0 secunde | Raspuns gresit. | 5 | 0 | ||
11 | 0 secunde | Raspuns gresit. | 5 | 0 | ||
12 | 0 secunde | Raspuns gresit. | 10 | 0 | ||
Punctaj total | 10 |
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema luna 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ă.