def zip_to_coord(zipcode,googlegeokey):
    '''
    Purpose:        The purpose of this script is to convert ZIP Code to a Latitude and Longitude
    Inputs:         zipcode: 5 digit long ZIP code.
    Outputs:        coord: tuple holding latitude and longitude
    Returns:        (lat,lon)
    Assumptions:    The EXIF data is valid.
    '''
    try:
        url = 'https://maps.googleapis.com/maps/api/geocode/json?address='+zipcode+'&key='+googlegeokey
        c = urllib2.urlopen(url)
        results = c.read()
        parsedResults = json.loads(results)
	lat = float(parsedResults['results'][0]['geometry']['location']['lat'])
        lon = float(parsedResults['results'][0]['geometry']['location']['lng'])

    except Exception:
        print "Unable to retrieve data: ", sys.exc_info()[0]
        (lat,lon) = (0.0,0.0)

    finally:
        return (lat,lon)