#1256
Sa se verifice dacă o listă simplu înlănțuită formează un palindrom.
Problema | FListaVerPalindrom | Operații I/O |
![]() flistaverpalindrom.in /flistaverpalindrom.out
|
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 4 MB
/
Stivă 4 MB
|
Id soluție | #58105593 | Utilizator | |
Fișier | flistaverpalindrom.cpp | Dimensiune | 349 B |
Data încărcării | 14 Mai 2025, 12:36 | Scor / rezultat | Eroare de compilare |
flistaverpalindrom.cpp: In function 'void add(node*&, char)': flistaverpalindrom.cpp:25:16: error: 'next' was not declared in this scope nou->next=next; ^ flistaverpalindrom.cpp: In function 'bool palindrom(node*)': flistaverpalindrom.cpp:30:14: error: expected initializer before '*=' token node ogl*=NULL; ^ flistaverpalindrom.cpp:32:13: error: 'ogl' was not declared in this scope add(ogl,p->key) ^ flistaverpalindrom.cpp:33:6: error: expected ';' before 'for' for(node*p=prim,*q=ogl;p!=NULL;p=p->next,q=q->next) ^ flistaverpalindrom.cpp:33:29: error: 'p' was not declared in this scope for(node*p=prim,*q=ogl;p!=NULL;p=p->next,q=q->next) ^ flistaverpalindrom.cpp:33:47: error: 'q' was not declared in this scope for(node*p=prim,*q=ogl;p!=NULL;p=p->next,q=q->next) ^ flistaverpalindrom.cpp:33:56: error: expected ';' before ')' token for(node*p=prim,*q=ogl;p!=NULL;p=p->next,q=q->next) ^ flistaverpalindrom.cpp:37:16: error: a function-definition is not allowed here before '{' token int main(void) { ^ flistaverpalindrom.cpp:66:1: error: expected '}' at end of input } ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema FListaVerPalindrom 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ă.