Question
In Python, which comparison about Counter and Frequency Maps is accurate?
- Counter expresses frequency logic directly, while a plain dict can do the same job with more manual update code.
- There is no practical difference in behavior, performance, or maintainability when Counter and Frequency Maps is involved.
- The oldest option related to Counter and Frequency Maps is always the right production choice regardless of workload or context.
- Differences around Counter and Frequency Maps 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: A. Counter expresses frequency logic directly, while a plain dict can do the same job with more manual update code.
Counter expresses frequency logic directly, while a plain dict can do the same job with more manual update code. This is the comparison that usually separates memorization from understanding.
Track: Python