2

Python newbie here. The docs have an example for OrderedDict usage:

class LRU(OrderedDict):
    'Limit size, evicting the least recently looked-up key when full'

    def __init__(self, maxsize=128, /, *args, **kwds):
        self.maxsize = maxsize
        super().__init__(*args, **kwds)

What is the / in the __init__ method signature?

Abhijit Sarkar
  • 19,114
  • 16
  • 94
  • 178

0 Answers0