Please find assignment 2 details with respective of task.