Added some comments, tinkered with white space;