{"raw_statement":[{"iden":"statement","content":"Your 5-year-old cousin from the CodeRams Contest #5 (Problem 4) is now in 4th grade, and he is learning how to simplify fractions. Unfortunately, he doesn't really understand them, and he needs your help in simplifying fractions.\n\nFor this problem, you must write a program to convert a fraction $a$/$b$ to simplest form. For example, if the fraction was $6$/$8$, you can factor out a $2$, and the fraction simplifies to $3$/$4$, which is in simplest form.\n\nThe only line of input contains a single fraction $a$/$b$: the fraction you need simplify. $a$/$b$ can be greater than one, but $a$ will not be a multiple of $b$. So $3$/$2$ would be a valid input, but $6$/$2$ would not.\n\nOutput a single fraction $c$/$d$ in the same format as the input: the input fraction, in simplest form, as described above.\n\nIn this problem, the input will be small enough for a brute force solution that tries all factors to run efficiently.\n\n"},{"iden":"input","content":"The only line of input contains a single fraction $a$/$b$: the fraction you need simplify. $a$/$b$ can be greater than one, but $a$ will not be a multiple of $b$. So $3$/$2$ would be a valid input, but $6$/$2$ would not."},{"iden":"output","content":"Output a single fraction $c$/$d$ in the same format as the input: the input fraction, in simplest form, as described above."},{"iden":"examples","content":"Input6/8\nOutput3/4\nInput72/48\nOutput3/2\nInput37/73\nOutput37/73\n"},{"iden":"note","content":"In this problem, the input will be small enough for a brute force solution that tries all factors to run efficiently."}],"translated_statement":null,"sample_group":[],"show_order":[],"formal_statement":"**Definitions**  \nLet $ a, b \\in \\mathbb{Z}^+ $ be integers such that $ 1 \\leq a, b \\leq 100 $, $ a \\not\\equiv 0 \\pmod{b} $, and the fraction is $ \\frac{a}{b} $.\n\n**Constraints**  \n1. $ \\gcd(a, b) > 1 $ (since the fraction is not already in simplest form)  \n2. $ a \\not\\equiv 0 \\pmod{b} $ (i.e., the fraction is not an integer)\n\n**Objective**  \nFind integers $ c, d \\in \\mathbb{Z}^+ $ such that:  \n$$\n\\frac{c}{d} = \\frac{a}{b} \\quad \\text{and} \\quad \\gcd(c, d) = 1\n$$  \nOutput $ \\frac{c}{d} $, where $ c = \\frac{a}{\\gcd(a,b)} $, $ d = \\frac{b}{\\gcd(a,b)} $.","simple_statement":"Simplify the fraction a/b to its lowest terms and output it as c/d.","has_page_source":false}