#294
Se dă un şir cu n elemente, numere naturale. Să se verifice dacă oglinditul primului element apare printre celelalte elemente ale șirului.
| Problema | EgaleOglindit | Operații I/O |
tastatură/ecran
|
|---|---|---|---|
| Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
| Id soluție | #64492648 | Utilizator | |
| Fișier | egaleoglindit.cpp | Dimensiune | 299 B |
| Data încărcării | 11 Mai 2026, 09:15 | Scor/rezultat | Eroare de compilare |
egaleoglindit.cpp: In function ‘int main()’: egaleoglindit.cpp:14:20: error: expected ‘(’ before ‘v’ 14 | if v[i] % 10 == v[i + 1] / 10 && if v[i] / 10 == v[i + 1] % 10; | ^ | ( egaleoglindit.cpp:17:17: error: ‘else’ without a previous ‘if’ 17 | else | ^~~~ egaleoglindit.cpp:18:29: error: expected ‘;’ before string constant 18 | cout "NU"; | ^~~~~ | ; egaleoglindit.cpp:18:25: warning: statement has no effect [-Wunused-value] 18 | cout "NU"; | ^~~~ egaleoglindit.cpp:19:34: error: expected ‘}’ at end of input 19 | return 0; | ^ egaleoglindit.cpp:5:1: note: to match this ‘{’ 5 | { | ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema EgaleOglindit 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ă.