from math import gcd from functools import reduce from sys import stdin, stdout input = lambda: stdin.readline().rstrip() write = stdout.write def main(): T = list(map(int, stdin.read().splitlines())) lcm = lambda x, y: x * y // gcd(x, y) lcm_ = reduce(lcm, T) loop = [] for i in T: loop.append(lcm_ // i) den = 1 for i in range(1, 11): mod = [] for j in loop: mod.append(j % i) if mod[0] == mod[1] == mod[2]: den = i ans = str(lcm_) + '/' + str(den) + '\n' write(ans) main()