completed some of the JS practice problems