python-hard-way/passing-parms.py

10 lines
229 B
Python

def no_side_effects(cities, cows):
print(cities)
cities = cities + ["Birmingham", "Bradford"]
print(cities)
print(cows)
locations = ["London", "Leeds", "Glasgow", "Sheffield"]
no_side_effects(locations, "Fred")