import urllib

# Precondition for all functions in this module: Each line of the url
# file contains the average monthly temperatures for a year (separated
# by spaces) starting with January.  The file must also have 3 header
# lines.

# Instead of using the terms "url" or "file", we use the more general
# term "reader" to indicate an open file or webpage.

def open_temperature_file(url):
    '''Open the specified URL, read past the three-line header, and 
    return the open reader.'''

    pass


def avg_temp_march(r):
    '''Return a float that is the average temperature for the month of March
    over all years in the reader r.'''

    pass


def avg_temp(r, mo):
    '''Return a float that is the average temperature for month mo over all
    years in the reader r. mo is an integer between 0 and 11, representing
    January to December, respectively.'''

    pass


def higher_avg_temp(url, mo1, mo2):
    '''Return either mo1 or mo2 (integers representing months in the
    range 0 to 11), whichever has the higher average temperature over
    all years in the webpage at the given url.  If the months have the 
    same average temperature, then return -1.'''

    pass


def three_highest_temps(r):
    '''Return a list of floats that contains the three highest
    temperatures, in descending order, over all months and years in
    the reader r.'''

    pass


def below_freezing(r):
    '''Return a list of floats in ascending order that contains all
    temperatures below freezing (32 degrees Fahrenheit), for all months and
    years in the reader r. Include any duplicates that occur.'''

    pass


