learning javascript one problem at a time