Your question is Python Key-Value Program. Start with the requirements on the right.
Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.
Beyondsoft configuration rollout tooling records key-value updates over time. Given the update history and a set of query timestamps, return the complete configuration snapshot visible at each query time.
An update is represented as [timestamp, key, value]. Timestamps are integers and are not necessarily provided in sorted order. If value is null, the key is deleted. Every update with timestamp <= query_timestamp must be applied before producing that query's snapshot. Query results must remain in the same order as the input queries.
Implement reconstruct_snapshots(operations, queries).
operations is a list of lists, where each item contains an integer timestamp, a string key, and either a string value or null.queries is a list of integer timestamps.i contains the key-value state at queries[i].def reconstruct_snapshots(operations, queries):