24.6: Explain why program inspections are an effective technique for discovering errors in a program. What types of error are unlikely to be discovered through inspections?
Program inspections are an effective technique because of a few reasons. First, it is difficult for the person writing the code to see their own errors. After having looked at the code for so long, errors are easily overlooked. By having a fresh set of eyes look at the code, seemingly working code can have errors found quickly. Also, program inspections are an affordable way to discover errors. The code doesn’t necessarily need to be run, and individual classes or methods can be reviewed apart from the full program.
Errors that are unlikely to be discovered are probably related to full program interaction rather than individual classes. Although the code looks good in classes/methods when viewed separately, when they are all put together and compiled and ran, errors can show up.