Exam-style question
Try this first
Which feature best demonstrates self-documenting code?.
- A.Using meaningful identifiers and well-structured code
- B.Adding comments to every line of code
- C.Using the shortest possible variable names
- D.Putting all code in one large section
Model answer
What a good answer should say
- Using meaningful identifiers and well-structured code
Explanation
Why this works
Self-documenting code uses meaningful identifiers and a clear structure, reducing the number of comments needed to understand it.
Common mistake
No common mistake is linked to this question yet.
