Updated comments and formatting for consistency.