Pregunta de entrevista de Yelp

Find maximum(minimum) cost path in matrix.