def percent2float(percent):
    """
    Converts a string with a percentage to a float.
    """
    percent = percent.replace(" ", "")
    percent = percent.strip("%")

    return float(percent) / 100