Implemented step 6