Apr-18-2017, 12:40 AM
Run it this way -- see the value of print statements
def fizz_count(x): count = 0 print(x) for y in x: print(y) if x[y] == "fizz": count = count + 1 print count GroceryItems = ["fizz","soda", "apple", "fizz", "fizz"] fizz_count(GroceryItems)