x=input() if '.' not in x: print(x+'/'+'1') else: i=len(x)-x.index('.')-1 x=int(x.replace('.','')) y=pow(10,i) from math import gcd num=gcd(x,y) print(str(x//num)+'/'+str(y//num))