my solution of the test task