""" func extractCities() open the file read one line to trash header create empty list for the cities for every additional line in the file split the line to get the city add the city to the list return the list """ def extractCities(): fin = open("IA_population_data.txt","r") fin.readline() #throw away the header line cities = [] for line in fin: data = line.split("\t") city = data[0] cities.append(city) fin.close() return cities """ function lookFor(list of cities, target city) for eachcity in list of cities if eachcity is the targetcity return True return False """ def lookFor(cities,target): for name in cities: if name==target: return True return False