Improve comments and formatting.