def f_to_c(val):
    """
    Converts Fahrenheit to Celsius; accepts numeric or string
    """
    try:
        return (float(val) - 32.) * 5. / 9.
    except (TypeError, ValueError):
        return (val - 32.) * 5. / 9.