Python: Which statement about Logging is the strongest interview answer?

Difficulty:

Easy

Questions:

1

Time Limit:

2 minutes

Passing Score:

100%

Question

Which statement about Logging is the strongest interview answer?

  1. Logging is mostly a naming style choice and has little effect on runtime behavior or design tradeoffs.
  2. Logging exists mainly to reduce the number of files in a Python project.
  3. Logging records meaningful runtime events so operators and developers can reconstruct behavior without attaching a debugger.
  4. Logging matters only for frontend scripting and not for backend or automation code.

Hint

Start with the core rule behind Logging.

Answer and rationale

Correct answer: C. Logging records meaningful runtime events so operators and developers can reconstruct behavior without attaching a debugger.

Logging records meaningful runtime events so operators and developers can reconstruct behavior without attaching a debugger. This is the base concept interviewers commonly test first.

Track: Python