Reported interview periodOct 2025–Jun 2026
Design a Type-Safe Durable LRU Cache
Extend a crash-recoverable LRU cache to support built-in containers and explicitly registered domain objects without using unsafe object serialization.
Practice focusRequirements - Produce canonical, type-tagged keys for None , booleans, integers, finite floats, strings, bytes, lists, tuples, dictionaries, sets, frozensets, and registered objects. - Preserve distinctions such as True , 1 , and 1.0 ; make dictionary and set identity independent of iteration order. - Allowlist exact classes through unique stable tags. Never dynamically import a class named by stored data. - Encode and decode cached values through the registry and reject unknown or malformed tags.…