MCPcopy Create free account
hub / github.com/dabeaz/python-cookbook / countdown

Function countdown

src/15/consuming_an_iterable_from_c/example.py:5–8  ·  view source on GitHub ↗
(n)

Source from the content-addressed store, hash-verified

3sample.consume_iterable([1,2,3,4])
4
5def countdown(n):
6 while n > 0:
7 yield n
8 n -= 1
9
10sample.consume_iterable(countdown(10))

Callers 1

example.pyFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected