manipulating arrays js exercise