numerator = input("Numerator = ")
denominator = input("Denominator = ")
if abs(unmerator) >= abs(denominator) :
whole = numerator // denominator
new_numerator = (numerator % denominator) * denominator
new_numerator = math.ceil(new_numerator)
print '%s + %s / %s' % (whole, new_numerator, denominator)
else : print "%s/%s" % (numerator, denominator)
# your code goes here
bnVtZXJhdG9yID0gaW5wdXQoIk51bWVyYXRvciA9ICIpCmRlbm9taW5hdG9yID0gaW5wdXQoIkRlbm9taW5hdG9yID0gIikKaWYgYWJzKHVubWVyYXRvcikgPj0gYWJzKGRlbm9taW5hdG9yKSA6CiAgICB3aG9sZSA9IG51bWVyYXRvciAvLyBkZW5vbWluYXRvcgogICAgbmV3X251bWVyYXRvciA9IChudW1lcmF0b3IgJSBkZW5vbWluYXRvcikgKiBkZW5vbWluYXRvcgogICAgbmV3X251bWVyYXRvciA9IG1hdGguY2VpbChuZXdfbnVtZXJhdG9yKQogICAgcHJpbnQgJyVzICsgJXMgLyAlcycgJSAod2hvbGUsIG5ld19udW1lcmF0b3IsIGRlbm9taW5hdG9yKQplbHNlIDogcHJpbnQgIiVzLyVzIiAlIChudW1lcmF0b3IsIGRlbm9taW5hdG9yKQojIHlvdXIgY29kZSBnb2VzIGhlcmU=
Traceback (most recent call last):
File "/usr/lib/python3.4/py_compile.py", line 124, in compile
_optimize=optimize)
File "<frozen importlib._bootstrap>", line 1532, in source_to_code
File "<frozen importlib._bootstrap>", line 321, in _call_with_frames_removed
File "./prog.py", line 7
print '%s + %s / %s' % (whole, new_numerator, denominator)
^
SyntaxError: invalid syntax
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/usr/lib/python3.4/py_compile.py", line 128, in compile
raise py_exc
py_compile.PyCompileError: File "./prog.py", line 7
print '%s + %s / %s' % (whole, new_numerator, denominator)
^
SyntaxError: invalid syntax