updated LRUCache.h with better code