#include<stdio.h>
int gcd(int n,int m)
{
int temp,r;
if(n<m)
{
temp=n;
n=m;
m=temp;
}
while(m!=0)
{
r=n%m;
n=m;
m=r;
}
return n;
}
void main()
{
int a,b;//a是分子 b是分母
printf("please input a and b:");
scanf("%d%d",&a,&b);
printf("%d/%d",a/gcd(a,b),b/gcd(a,b));
}