alg:print optimal solution of matrix chain order problem