Task #4 solution