Pregunta de entrevista de Amazon

Rod cutting problem on dynamic programming