Task 01 and 02 refactoring and added 3,4 and 5