Added solution for step 3