Skip to interview prep
Apexed

75. Implement a fixed-capacity LRU cache with get and put. How would you handle updates and prove that eviction stays correct?

MediumData structures & algorithms

TechnicalAmazon · Topic report
Sources & context
  • Glassdoor: Amazon SDE II candidate report · Report published

    An anonymous candidate report mentions LRU caching plus deadline and incomplete-information behavioral topics. Independently unverified; publication date, not interview date. Related original practice, not the reported wording.

Write a solution in JavaScript or Python, add a few test calls that print results and press Run. This is ungraded practice: Run shows output and does not check correctness. Open the Model answer tab to compare. Your code is saved in this browser.

Tab indents · Ctrl/⌘ + Enter runs · Esc then Tab leaves the editor

Press Run to see your program’s output.

Implement a fixed-capacity LRU cache with get and put. How would you handle updates and prove that eviction stays correct — Software engineering interview quest