added solution to task 7