Problem gcd
User shawn
Submission Time 2024-05-09 15:02:07
Score 0
Max Time N/A
Max Memory N/A

Compile Error

gcd.cpp:5:8: error: ‘a’ was not declared in this scope
5 | ll gcd(a, b){
| ^
gcd.cpp:5:11: error: ‘b’ was not declared in this scope
5 | ll gcd(a, b){
| ^
gcd.cpp:5:12: error: expression list treated as compound expression in initializer [-fpermissive]
5 | ll gcd(a, b){
| ^
gcd.cpp: In function ‘int main()’:
gcd.cpp:15:10: error: reference to ‘gcd’ is ambiguous
15 | cout << gcd(a, b);
| ^~~
In file included from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:84,
from gcd.cpp:1:
/usr/include/c++/9/numeric:132:5: note: candidates are: ‘template<class _Mn, class _Nn> constexpr std::common_type_t<_Mn, _Nn> std::gcd(_Mn, _Nn)’
132 | gcd(_Mn __m, _Nn __n) noexcept
| ^~~
gcd.cpp:5:4: note: ‘ll gcd’
5 | ll gcd(a, b){
| ^~~