These implementations are for demonstration purposes. They are less efficient than the implementations in the Python standard library.
Fewer brackets, more smart devices.