The document provides 8 tips for commenting code, including commenting each level of code, using paragraph comments to describe blocks of code, aligning consecutive line comments, avoiding obvious comments, being polite in comments, commenting while writing code, updating comments when updating code, and emphasizing readable code that requires fewer comments.