Pregunta de entrevista de Amazon

DP Programming problem regarding how to code robot to move along a certain pathway.