← back to apps
> typing speed test
Type real code snippets as fast as you can. Measure your WPM and accuracy.
PythonDecorator
—
WPM
—
Accuracy
0:00
Time
0%
decorator.py
def cache(max_size=128):↵ def decorator(func):↵ store = {}↵ def wrapper(*args):↵ if args in store:↵ return store[args]↵ result = func(*args)↵ if len(store) >= max_size:↵ store.pop(next(iter(store)))↵ store[args] = result↵ return result↵ return wrapper↵ return decorator
start typing to begin...