Practice · 2 of 2
Two Storages, One Interface
CHALLENGE
Difficulty: intermediate+25 XP
Implement MemoryStorage (dict-backed) and class PrefixedStorage wrapping another storage and adding 'p:' to every key on save and load (delegation + composition). Both satisfy the Storage protocol from the lesson.
Press Submit to check your solution.
Back to lesson: Practice: Protocol Drills