diff --git a/mypy.ini b/mypy.ini index 7dbc7c4ffc80..de473bbb2bc6 100644 --- a/mypy.ini +++ b/mypy.ini @@ -2,4 +2,3 @@ ignore_missing_imports = True install_types = True non_interactive = True -exclude = (other/least_recently_used.py) diff --git a/other/least_recently_used.py b/other/least_recently_used.py index 9d6b6d7cb6a6..302a06c1fd3b 100644 --- a/other/least_recently_used.py +++ b/other/least_recently_used.py @@ -1,10 +1,13 @@ import sys +from abc import ABCMeta from collections import deque class LRUCache: """Page Replacement Algorithm, Least Recently Used (LRU) Caching.""" + __metaclass__ = ABCMeta + dq_store = object() # Cache store of keys key_reference_map = object() # References of the keys in cache _MAX_CAPACITY: int = 10 # Maximum capacity of cache