#3158
numere123
Se citește un număr natural n
având cifrele diferite două câte două. Afișați în ordine crescătoare numerele care se pot obține din cifrele lui n
și care au același număr de cifre ca n
.
Problema | numere123 | Operații I/O | tastatură/ecran |
---|---|---|---|
Limita timp | 0.4 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #53762251 | Utilizator | |
Fișier | numere123.cpp | Dimensiune | 920 B |
Data încărcării | 11 Noiembrie 2024, 09:53 | Scor / rezultat | Eroare de compilare |
numere123.cpp: In function 'int valid()': numere123.cpp:12:20: warning: suggest parentheses around assignment used as truth value [-Wparentheses] if(st[k]=st[i]) ^ numere123.cpp: In function 'void tipar()': numere123.cpp:21:6: error: 'cout' was not declared in this scope cout<<st[i]<<' '; ^ numere123.cpp:21:6: note: suggested alternative: In file included from numere123.cpp:1:0: /usr/include/c++/4.8/iostream:61:18: note: 'std::cout' extern ostream cout; /// Linked to standard output ^ numere123.cpp:22:5: error: 'cout' was not declared in this scope cout<<endl;} ^ numere123.cpp:22:5: note: suggested alternative: In file included from numere123.cpp:1:0: /usr/include/c++/4.8/iostream:61:18: note: 'std::cout' extern ostream cout; /// Linked to standard output ^ numere123.cpp:22:11: error: 'endl' was not declared in this scope cout<<endl;} ^ numere123.cpp:22:11: note: suggested alternative: In file included from /usr/include/c++/4.8/iostream:39:0, from numere123.cpp:1: /usr/include/c++/4.8/ostream:564:5: note: 'std::endl' endl(basic_ostream<_CharT, _Traits>& __os) ^ numere123.cpp: In function 'void back()': numere123.cpp:30:10: error: 'else' without a previous 'if' {else k++; init();} ^ numere123.cpp:31:9: error: 'else' without a previous 'if' else k--;} ^ numere123.cpp: In function 'int main()': numere123.cpp:35:5: error: 'cin' was not declared in this scope cin>>n; ^ numere123.cpp:35:5: note: suggested alternative: In file included from numere123.cpp:1:0: /usr/include/c++/4.8/iostream:60:18: note: 'std::cin' extern istream cin; /// Linked to standard input ^ numere123.cpp:46:19: warning: suggest parentheses around assignment used as truth value [-Wparentheses] } while(ord=0); ^ numere123.cpp:48:9: error: 'cout' was not declared in this scope cout<<v[i]<<' '; ^ numere123.cpp:48:9: note: suggested alternative: In file included from numere123.cpp:1:0: /usr/include/c++/4.8/iostream:61:18: note: 'std::cout' extern ostream cout; /// Linked to standard output ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema numere123 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ă.