problem 5 javascript