#include<iostream>
using namespace std;
int main()
{
int x,y;
cin>>x>>y;
if (x < y)
{
int tmp = y;
y = x;
x = tmp;
}
for (int i = y; i >= 1; i-- )
{
if (x%i == 0 && y%i == 0)
{
return i;
}
}
标签:tmp,std,return,int,5.17,main From: https://www.cnblogs.com/lml66/p/17410617.html