Skip to content

Instantly share code, notes, and snippets.

View codeInn001's full-sized avatar
💭
🖥⌨

Alege Emmanuel Oluwasegun codeInn001

💭
🖥⌨
View GitHub Profile
@lilpolymath
lilpolymath / LRUCache.md
Created April 12, 2022 14:30
Implementing a given cache size behaving as an LRU cache with an expiry time and auto cache burst

Question

Implement Promise based memoization with a given cache size behaving as an LRU cache with an expiry time and auto cache burst.

Answer

First, what we have to do is breakdown the terms in the problem statement to understand what is going on and what we are asked to do.

  1. Promise based memoization: Memoization is one of the ways we can improve the performance of functions by eliminating redundant calls. Memoization is a technique where we store the results of a function call in a cache and return the result from the cache if the function is called again with the same arguments.
@arthurgousset
arthurgousset / a16z-crypto-canon.md
Last active May 21, 2022 14:53
a16z's Crypto Canon (markdown)