updated to exercise 5.4