Morgan Stanley SDE OA 2024 | Book Inventory & Event Stalls Route

Question · Posted Jun 2026

Problem 1 - Book Inventory Problem Statement A library manages its inventory using a Least Recently Used (LRU) replacement strategy. Whenever a book is requested: If the book already exists in the inventory, it becomes the most recently used book. If the book does not exist and there is available space, it is added to the inventory. If the book does not exist and the inventory is full, the least recently used book is removed and the requested book is ...

The full answer & interview discussion are available to premium members.

Log in Create a free account