def format_code(entry):
 code = ''
 for line in entry.split('\n'):
  code += ('\n{G>>>{n %s' % line)
 return code.strip()

def format_code ( entry ) : code = '' for line in entry . split ( '\n' ) : code += ( '\n{G>>>{n %s' % line ) return code . strip ( )
formats the viewing of code and errors .