Added headers, comments to improve clarity, and limited the size of lines to 80 chars