Python: In Python, which comparison about Global Interpreter Lock (GIL) is accurate?

Difficulty:

Easy

Questions:

1

Time Limit:

2 minutes

Passing Score:

100%

Question

In Python, which comparison about Global Interpreter Lock (GIL) is accurate?

  1. There is no practical difference in behavior, performance, or maintainability when Global Interpreter Lock (GIL) is involved.
  2. The GIL limits CPU-bound threading speedups, while I/O-bound programs can still benefit because threads release control while waiting.
  3. The oldest option related to Global Interpreter Lock (GIL) is always the right production choice regardless of workload or context.
  4. Differences around Global Interpreter Lock (GIL) are mostly cosmetic, so correctness and debugging quality do not really change.

Hint

Focus on the behavior or tradeoff, not just the keyword.

Answer and rationale

Correct answer: B. The GIL limits CPU-bound threading speedups, while I/O-bound programs can still benefit because threads release control while waiting.

The GIL limits CPU-bound threading speedups, while I/O-bound programs can still benefit because threads release control while waiting. This is the comparison that usually separates memorization from understanding.

Track: Python