improved comments, removed old debug statements