Junior — Senior
In-memory cache with individual expiration time for records
livecode
Task condition
Implement a cache that is stored in RAM and has the following properties:
- each element is a pair k → v;
- each v can have its own TTL (time-to-live) parameter;
- after the specified TTL expires, the value should be automatically removed from the cache without external requests.