Showing 3 questions
Simulate a simple bank system that supports basic operations like deposit, withdraw, and check balance for different accounts. You will implement methods to handle these transactions and ensure validity based on account balances and existence.
#1. Simple Bank System
Implement an iterator that cycles through multiple lists in a zigzag pattern. The iterator should return elements from each list in turn until all elements are exhausted.
#2. Zigzag Iterator
Design a key-value store that supports storing values associated with timestamps. You should be able to retrieve the value for a given key at the latest timestamp less than or equal to a given time.
#3. Time Based Key-Value Store