#include <stdio.h>
main()
{
int m,n,k,i;
printf("please input a fenshu:");
scanf("%d/%d",&n,&m);
while(1)
{
if(m%n==0)
{
m=m/n;
n=1;
}
else i=m/n+1;
if(n==1)
{
printf("1/%d\n",m);
break;
}
else
{
printf("1/%d +",i);
n=n*i-m;
m=m*i;
}
if(n==3)
{
printf("1/%d + 1/%d",m/2,m);
break;
}
}
}