def rivers_with_station(stations):
    """set made to prevent duplicates, river names added for each station to the set, set of rivers returned."""
    rivers = set()
    for station in stations:
        rivers.add(station.river) 
    return rivers