Skip to content

Instantly share code, notes, and snippets.

@modos
Created April 26, 2023 05:52
Show Gist options
  • Save modos/56087e7cc16945b1f31a359fa48e7715 to your computer and use it in GitHub Desktop.
Save modos/56087e7cc16945b1f31a359fa48e7715 to your computer and use it in GitHub Desktop.
ب.م.م
#include <iostream>
using namespace std;
long long gcd(long long a, long long b)
{
return (b == 0LL ? a : gcd(b, a % b));
}
int main()
{
long long a, b;
cin >> a >> b;
cout << gcd(a, b) << '\n';
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment