All challenges
Multiple ChoiceIntermediate 30s

functools.lru_cache Performance

Choose the best answer for: lru_cache benefit
Options
  1. 1lru_cache is for async coroutines and never for sync calls
  2. 2lru_cache avoids recomputing expensive function calls
  3. 3lru_cache adds overhead and never saves any work
  4. 4lru_cache is for caching to disk rather than in memory

Think you can answer under pressure?

Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.

Play this in a 3-minute battle