MCPcopy Index your code
hub / github.com/python/cpython / G

Class G

Lib/test/test_itertools.py:2122–2127  ·  view source on GitHub ↗

Sequence using __getitem__

Source from the content-addressed store, hash-verified

2120 yield i
2121
2122class G:
2123 'Sequence using __getitem__'
2124 def __init__(self, seqn):
2125 self.seqn = seqn
2126 def __getitem__(self, i):
2127 return self.seqn[i]
2128
2129class I:
2130 'Sequence using iterator protocol'

Callers 1

LFunction · 0.70

Calls

no outgoing calls

Tested by 1

LFunction · 0.56