ocaml: phase 5.1 euler36.ml baseline (sum of double-base palindromes <= 1000 = 1772)
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 23s
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 23s
Numbers that read the same in base 10 and base 2: 1, 3, 5, 7, 9, 33, 99, 313, 585, 717 sum = 1772 Implementation: pal_dec n check decimal palindrome via index walk to_binary n build binary string via mod 2 / div 2 stack pal_bin n check binary palindrome euler36 limit scan 1..limit-1, sum where both palindromes Real PE36 uses 10^6 (answer 872187). 1000 takes ~9 minutes on contended host but stays within reasonable budget for the spec-level evaluator. 123 baseline programs total.
This commit is contained in:
@@ -36,6 +36,7 @@
|
||||
"euler29_small.ml": 15,
|
||||
"euler30_cube.ml": 1301,
|
||||
"euler34_small.ml": 145,
|
||||
"euler36.ml": 1772,
|
||||
"euler40_small.ml": 15,
|
||||
"euler3.ml": 29,
|
||||
"euler4_small.ml": 9009,
|
||||
|
||||
Reference in New Issue
Block a user