Edited some comments and changed some methods