#1174
FListaNumarare2
C++
Să se scrie o funcție C++ care determină câte perechi de elemente prime între ele sunt memorate într-o lista simplu înlănțuită.
Problema | FListaNumarare2 | Operații I/O | tastatură/ecran |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #50158104 | Utilizator | |
Fișier | flistanumarare2.cpp | Dimensiune | 441 B |
Data încărcării | 29 Martie 2024, 08:08 | Scor / rezultat | Eroare de compilare |
flistanumarare2.cpp: In function 'int numarare(nod*)': flistanumarare2.cpp:40:13: error: conversion from 'nod*' to non-scalar type 'nod' requested nod q = head; ^ flistanumarare2.cpp:41:14: error: base operand of '->' has non-pointer type 'nod' nod p = q->urm; ^ flistanumarare2.cpp:42:12: error: base operand of '->' has non-pointer type 'nod' while(q->urm != NULL) ^ flistanumarare2.cpp:44:13: error: base operand of '->' has non-pointer type 'nod' if(p->urm == NULL) ^ flistanumarare2.cpp:46:18: error: base operand of '->' has non-pointer type 'nod' q = q->urm; ^ flistanumarare2.cpp:47:18: error: base operand of '->' has non-pointer type 'nod' p = q->urm; ^ flistanumarare2.cpp:49:13: error: base operand of '->' has non-pointer type 'nod' if(q->info % p->info != 0 && p->info % q->info != 0) ^ flistanumarare2.cpp:49:23: error: base operand of '->' has non-pointer type 'nod' if(q->info % p->info != 0 && p->info % q->info != 0) ^ flistanumarare2.cpp:49:39: error: base operand of '->' has non-pointer type 'nod' if(q->info % p->info != 0 && p->info % q->info != 0) ^ flistanumarare2.cpp:49:49: error: base operand of '->' has non-pointer type 'nod' if(q->info % p->info != 0 && p->info % q->info != 0) ^ flistanumarare2.cpp:52:18: error: base operand of '->' has non-pointer type 'nod' p = p->urm; ^ flistanumarare2.cpp:56:18: error: base operand of '->' has non-pointer type 'nod' p = p->urm; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema FListaNumarare2 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ă.