Pregunta de entrevista de ABC

Tricky Dynamic programming questions were asked