Borderou de evaluare (job #3176843)
Utilizator | Data | 27 noiembrie 2023 21:00:57 | |
---|---|---|---|
Problema | Bile | Status | done |
Runda | Arhiva de probleme | Compilator | cpp-64 | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp: In function 'void readInput()':
main.cpp:17:18: error: reference to 'size' is ambiguous
17 | scanf("%d", &size);
| ^~~~
In file included from /usr/include/c++/12.2.1/string:52,
from /usr/include/c++/12.2.1/bitset:47,
from main.cpp:2:
/usr/include/c++/12.2.1/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
/usr/include/c++/12.2.1/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
main.cpp:7:5: note: 'int size'
7 | int size, size_squared;
| ^~~~
main.cpp:18:20: error: reference to 'size' is ambiguous
18 | size_squared = size * size;
| ^~~~
/usr/include/c++/12.2.1/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
/usr/include/c++/12.2.1/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
main.cpp:7:5: note: 'int size'
7 | int size, size_squared;
| ^~~~
main.cpp:18:27: error: reference to 'size' is ambiguous
18 | size_squared = size * size;
| ^~~~
/usr/include/c++/12.2.1/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
/usr/include/c++/12.2.1/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
main.cpp:7:5: note: 'int size'
7 | int size, size_squared;
| ^~~~
main.cpp:28:26: error: reference to 'size' is ambiguous
28 | for (int i = 1; i <= size; ++i) {
| ^~~~
/usr/include/c++/12.2.1/bits/range_access.h:274:5: note: candidates are: 'template<class _Tp, long unsigned int _Nm> constexpr std::size_t std::size(const _Tp (&)[_Nm])'
274 | size(const _Tp (&)[_Nm]) noexcept
| ^~~~
/usr/include/c++/12.2.1/bits/range_access.h:264:5: note: 'template<class _Container> constexpr decltype (__cont.size()) std::size(const _Container&)'
264 | size(const _Container& __cont) noexcept(noexcept(__cont.size()))
| ^~~~
main.cpp:7:5: note: 'int size'
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !