def read_map(file_name):
    """This function opens a file with the name in 'file_name', reads the map it
    contains. Stores each line of the file as strings in a list.
    pre: none, as this function handles IOError for when the file is not there gracefully
    post: Returns a list of strings."""
    map_file_list_of_rows = []
    try:
        open_file = open(file_name, 'r')            #Open the specified file
        for line in open_file:
            cleaned_line = line.strip()
            if 'W' in line:
                cleaned_line = cleaned_line.replace(" ", "")
            map_file_list_of_rows.append(cleaned_line)
        open_file.close()                           #Close the file
    except IOError:
        print("File does not exist! Try again.")    #If it can't find this file.
    return map_file_list_of_rows