#include<bits/stdc++.h>
using namespace std;

/*void tinh(int a,int b,int c,int d) 

{

	tu1=(a*d)+(b*c);
	mau1=b*d;
	tu2=a*c;
	mau2=b*d;
}
*/
void UCLN(int x, int y)
{
	int tg;
	while(x!=y)
	{
		if(y>x)
		{
			tg=x;
			x=y;
			y=tg;
		}
		y=x-y;
	}
	cout<<x<<y;
}

int main ()
{
	UCLN(12,6);

	
	
}
