Running `this.cache.shift()` on a larger array with key & values directly instead of objects took an enormous amount of time, that's why I'm invering the order in C++ and then doing `cache.pop()` instead.