Matrix chain multiplication: Difference between revisions

m
Regularize non-standard header markup
No edit summary
m (Regularize non-standard header markup)
Line 747:
</pre>
 
== {{header|MATLAB}} ==
{{trans|Fortran}}
 
Line 804:
 
"(1*((((((2*3)*4)*(((5*6)*7)*8))*9)*10)*11))"</lang>
== {{header|Lua}} ==
<lang lua>-- Matrix A[i] has dimension dims[i-1] x dims[i] for i = 1..n
local function MatrixChainOrder(dims)
Line 982:
</pre>
 
== {{header|Python}} ==
We will solve the task in three steps:
 
Line 1,187:
</pre>
 
== {{header|Racket}} ==
 
'''Memoization'''
Line 1,373:
</pre>
 
== {{header|Stata}} ==
=== Recursive solution ===
{{trans|Python}}
10,333

edits