def print_return(output=sys.stdout):
def decorator(func):<EOL><INDENT>"""<STR_LIT>"""<EOL>@wraps(func)<EOL>def _(*args, **kwargs):<EOL><INDENT>"""<STR_LIT>"""<EOL>res = func(*args, **kwargs)<EOL>output.write("<STR_LIT>".format(str(res)))<EOL>return res<EOL><DEDENT>return _<EOL><DEDENT>return decorator<EOL>
Decorate a function so that print result after calling it.

    Args:
      output: writable to print return values. (Default: sys.stdout)