Iterating over dictionary values

Just like an array, we can iterate through our dictionary. However, there are a few differences. Since a dictionary is unordered, each time you loop through, the values will never be in the same order. With dictionaries, you can loop through both the values and keys.

Let's iterate over a dictionary's values using a for...in loop. Add the following to Playgrounds:

for value in dictPizzas.values { 
  print(value) 
}

Your code should now look like this: