Solution for task 3.7 added