Problem | mathexam |
---|---|
User | Hytoh |
Submission Time | 2024-07-22 17:10:57 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
mathexam.cpp: In function ‘int main()’:
mathexam.cpp:56:45: error: no matching function for call to ‘holds_alternative<std::string>(long long int&)’
56 | if (holds_alternative<string>(result)) {
| ^
In file included from mathexam.cpp:9:
/usr/include/c++/9/variant:1057:5: note: candidate: ‘template<class _Tp, class ... _Types> constexpr bool std::holds_alternative(const std::variant<_Types ...>&)’
1057 | holds_alternative(const variant<_Types...>& __v) noexcept
| ^~~~~~~~~~~~~~~~~
/usr/include/c++/9/variant:1057:5: note: template argument deduction/substitution failed:
mathexam.cpp:56:45: note: mismatched types ‘const std::variant<_Types ...>’ and ‘long long int’
56 | if (holds_alternative<string>(result)) {
| ^
mathexam.cpp:57:39: error: no matching function for call to