task 5 lab 3 and unit test

analogically with previous