Borderou de evaluare (job #2716579)
Utilizator | Data | 5 martie 2021 12:53:49 | |
---|---|---|---|
Problema | Tromino | Status | done |
Runda | Arhiva de probleme | Compilator | cpp-64 | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp: In function 'long long int solve(int, long long int, long long int, long long int, long long int)':
main.cpp:42:79: error: call of overloaded 'abs(long long int)' is ambiguous
ans = ans + solve(k - 1, cornerx1, cornery1, x2, y2) + abs(cornerx1 - cornerx) + abs(cornery1 - cornery);
^
In file included from /usr/include/c++/6/cstdlib:75:0,
from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:47,
from main.cpp:1:
/usr/include/stdlib.h:774:12: note: candidate: int abs(int)
extern int abs (int __x) __THROW __attribute__ ((__const__)) __wur;
^~~
main.cpp:16:4: note: candidate: long long int abs(long long int)
ll abs (ll x) {
^~~
In file included from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:47:0,
from main.cpp:1:
/usr/include/c++/6/cstdlib:180:3: note: candidate: long long int std::abs(long long int)
abs(long long __x) { return __builtin_llabs (__x); }
^~~
/usr/include/c++/6/cstdlib:172:3: note: candidate: long int std::abs(long int)
abs(long __i) { return __builtin_labs(__i); }
^~~
In file included from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:41:0,
from main.cpp:1:
/usr/include/c++/6/cmath:103:5: note: candidate: constexpr typename __gnu_cxx::__enable_if<std::__is_integer<_Tp>::__value, double>::__type std::abs(_Tp) [with _Tp = long long int; typename __gnu_cxx::__enable_if<std::__is_integer<_Tp>::__value, double>::__type = double]
abs(_Tp __x)
^~~
/usr/include/c++/6/cmath:95:3: note: candidate: constexpr long double std::abs(long double)
abs(long double __x)
^~~
/usr/include/c++/6/cmath:91:3: note: candidate: constexpr float std::abs(float)
abs(float __x)
^~~
/usr/include/c++/6/cmath:85:3: note: candidate: constexpr double std::abs(double)
abs(double __x)
^~~
main.cpp:42:105: error: call of overloaded 'abs(long long int)' is ambiguous
ans = ans + solve(k - 1, cornerx1, cornery1, x2, y2) + abs(cornerx1 - cornerx) + abs(cornery1 - cornery);
^
In file included from /usr/include/c++/6/cstdlib:75:0,
from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:47,
from main.cpp:1:
/usr/include/stdlib.h:774:12: note: candidate: int abs(int)
extern int abs (int __x) __THROW __attribute__ ((__const__)) __wur;
^~~
main.cpp:16:4: note: candidate: long long int abs(long long int)
ll abs (ll x) {
^~~
In file included from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:47:0,
from main.cpp:1:
/usr/include/c++/6/cstdlib:180:3: note: candidate: long long int std::abs(long long int)
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !