implemented step 1b