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

Function test

Lib/turtledemo/penrose.py:132–143  ·  view source on GitHub ↗
(l=200, n=4, fun=sun, startpos=(0,0), th=2)

Source from the content-addressed store, hash-verified

130 resizemode("user")
131
132def test(l=200, n=4, fun=sun, startpos=(0,0), th=2):
133 global tiledict
134 goto(startpos)
135 setheading(0)
136 tiledict = {}
137 tracer(0)
138 fun(l, n)
139 draw(l, n, th)
140 tracer(1)
141 nk = len([x for x in tiledict if tiledict[x]])
142 nd = len([x for x in tiledict if not tiledict[x]])
143 print("%d kites and %d darts = %d pieces." % (nk, nd, nk+nd))
144
145def demo(fun=sun):
146 start()

Callers 2

demoFunction · 0.70
mainFunction · 0.70

Calls 3

tracerFunction · 0.85
drawFunction · 0.70
funFunction · 0.50

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…