MCPcopy Create free account
hub / github.com/TheAlgorithms/JavaScript /

Class

Cache/LFUCache.js:12–12  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

10
11// This frequency map class will act like javascript Map DS with more two custom method refresh & insert
12class FrequencyMap extends Map {
13 static get [Symbol.species]() {
14 return Map
15 } // for using Symbol.species we can access Map constructor @see -> https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/@@species

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected