Problem uniquenumbers
User vadar2525
Submission Time 2026-04-19 17:51:49
Score 0
Max Time N/A
Max Memory N/A

Compile Error

uniquenumbers.cpp: In function ‘int main()’:
uniquenumbers.cpp:16:13: error: cannot convert ‘__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type’ {aka ‘std::__cxx11::basic_string<char>’} to ‘long long int’ in initialization
16 | int x = a[0];
| ^
uniquenumbers.cpp:18:8: error: no match for ‘operator!=’ (operand types are ‘long long int’ and ‘__gnu_cxx::__alloc_traits<std::allocator<std::__cxx11::basic_string<char> >, std::__cxx11::basic_string<char> >::value_type’ {aka ‘std::__cxx11::basic_string<char>’})
18 | if(x != a[i]){
In file included from /usr/include/c++/9/regex:62,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:110,
from uniquenumbers.cpp:1:
/usr/include/c++/9/bits/regex.h:1037:5: note: candidate: ‘template<class _BiIter> bool std::__cxx11::opera