def reindent ( s , numspaces ) : leading_space = numspaces * ' ' lines = [ leading_space + line . strip ( ) for line in s . splitlines ( ) ] return '\n' . join ( lines )
python spreadstring on multiple lines
reinidents a string ( s ) by the given number of spaces ( numspaces )
def reindent(s, numspaces):
    """ reinidents a string (s) by the given number of spaces (numspaces) """
    leading_space = numspaces * ' '
    lines = [leading_space + line.strip()for line in s.splitlines()]
    return '\n'.join(lines)