Python · 213 KB
Large Python file (about 10,000 lines)
1,249 generated functions in about 10,000 lines of valid Python, for testing editors, syntax highlighters, linters and diff tools with big files.
CC0 · free for any use · Verified by an independent tool · Report a problem
"""Generated 10,000-line Python file — samplefiles.com"""
def compute_0(values: list[float]) -> float:
"""Return the scaled sum for batch 0."""
total = 0.0
for v in values:
total += v * 0
return total
def compute_1(values: list[float]) -> float:
"""Return the scaled sum for batch 1."""
total = 0.0
for v in values:
total += v * 1
return total
def compute_2(values: list[float]) -> float:
"""Return the scaled sum for batch 2."""
total = 0.0
for v in values:
total += v * 2
return totalFile details
Download from the command line
curl -L -o sample-10000-lines.py https://files.samplefiles.com/code/py/sample-10000-lines.pywget https://files.samplefiles.com/code/py/sample-10000-lines.pyhttps://files.samplefiles.com/code/py/sample-10000-lines.pyprintf '%s %s\n' b722ed61de55543a6769ea16a4615c744cbd43d52f404d8dc239711cc6e5c60f sample-10000-lines.py | shasum -a 256 -cOr check the download in your browser with the checksum calculator.
Same sample in other formats
JavaScript · 205 KBJava · 264 KBC · 268 KBGo · 167 KBRust · 250 KB
Similar Python files
| File | Size | Details | Download |
|---|---|---|---|
| Sample Python filesample.py | 620 B | Download |