ocaml: phase 5.1 grid_paths.ml baseline (count paths in 4x6 grid = 210)
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 25s
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 25s
DP filling a flattened 2D array: dp.(0, 0) = 1 dp.(i, j) = dp.(i-1, j) + dp.(i, j-1) index = i * (n+1) + j For a 4x6 grid (5x7 dp matrix), the count is C(10, 4) = 210. Tests Array as 2D via row-major flatten + nested for + multi-step conditional access (above/left guarded by 'if i > 0' / 'if j > 0'). 87 baseline programs total.
This commit is contained in:
@@ -31,6 +31,7 @@
|
||||
"frequency.ml": 5,
|
||||
"gcd_lcm.ml": 60,
|
||||
"grep_count.ml": 3,
|
||||
"grid_paths.ml": 210,
|
||||
"group_consec.ml": 53,
|
||||
"hailstone.ml": 111,
|
||||
"hanoi.ml": 1023,
|
||||
|
||||
Reference in New Issue
Block a user