implemented task #3