結果 : define principal of optimality explain its use in dynamic programming method