finish exercises in JS