Added possible solution for the task 8.