solution for hash exercise 5