Cleanup and addition of comments