def simplify(string):
    """Takes a string, strips spaces in each line and returns it
    Useful to compare strings when different versions of a code give
    different spaces."""
    return '\n'.join(s.strip() for s in string.split())