#247
CifreOrd1
Se dau mai multe numere naturale, fiecare cu cel mult 9
cifre. Să se afişeze, în ordine descrescătoare, toate cifrele care apar în numerele date.
Variante Bacalaureat 2009
Problema | CifreOrd1 | Operații I/O |
cifreord1.in /cifreord1.out
|
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #54156966 | Utilizator | |
Fișier | cifreord1.cpp | Dimensiune | 790 B |
Data încărcării | 20 Noiembrie 2024, 22:49 | Scor / rezultat | Eroare de compilare |
cifreord1.cpp: In function 'int main()': cifreord1.cpp:24:5: error: reference to 'count' is ambiguous count = 0; ^ cifreord1.cpp:9:15: note: candidates are: int count int i, digit, count; ^ In file included from /usr/include/c++/4.8/algorithm:62:0, from /usr/include/i386-linux-gnu/c++/4.8/bits/stdc++.h:64, from cifreord1.cpp:1: /usr/include/c++/4.8/bits/stl_algo.h:4622:5: note: template<class _IIter, class _Tp> typename std::iterator_traits<_Iterator>::difference_type std::count(_IIter, _IIter, const _Tp&) count(_InputIterator __first, _InputIterator __last, const _Tp& __value) ^ cifreord1.cpp:28:13: error: reference to 'count' is ambiguous count++; ^ cifreord1.cpp:9:15: note: candidates are: int count int i, digit, count; ^ In file included from /usr/include/c++/4.8/algorithm:62:0, from /usr/include/i386-linux-gnu/c++/4.8/bits/stdc++.h:64, from cifreord1.cpp:1: /usr/include/c++/4.8/bits/stl_algo.h:4622:5: note: template<class _IIter, class _Tp> typename std::iterator_traits<_Iterator>::difference_type std::count(_IIter, _IIter, const _Tp&) count(_InputIterator __first, _InputIterator __last, const _Tp& __value) ^ cifreord1.cpp:30:16: error: reference to 'count' is ambiguous if(count % 20 == 0){ ^ cifreord1.cpp:9:15: note: candidates are: int count int i, digit, count; ^ In file included from /usr/include/c++/4.8/algorithm:62:0, from /usr/include/i386-linux-gnu/c++/4.8/bits/stdc++.h:64, from cifreord1.cpp:1: /usr/include/c++/4.8/bits/stl_algo.h:4622:5: note: template<class _IIter, class _Tp> typename std::iterator_traits<_Iterator>::difference_type std::count(_IIter, _IIter, const _Tp&) count(_InputIterator __first, _InputIterator __last, const _Tp& __value) ^ cifreord1.cpp:38:8: error: reference to 'count' is ambiguous if(count % 20 != 0){ ^ cifreord1.cpp:9:15: note: candidates are: int count int i, digit, count; ^ In file included from /usr/include/c++/4.8/algorithm:62:0, from /usr/include/i386-linux-gnu/c++/4.8/bits/stdc++.h:64, from cifreord1.cpp:1: /usr/include/c++/4.8/bits/stl_algo.h:4622:5: note: template<class _IIter, class _Tp> typename std::iterator_traits<_Iterator>::difference_type std::count(_IIter, _IIter, const _Tp&) count(_InputIterator __first, _InputIterator __last, const _Tp& __value) ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema CifreOrd1 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ă.