Amazon Interview Question

2 questions: First was an easy 1D array problem required to be solved in linear time. Second was a Medium difficulty 2D array matrix requiring graph search.

Interview Answer

Anonymous

Nov 1, 2017

Got the first one in 5 mins with efficient solution but got stuck in the second one. Got a non-optimal solution after 20 mins after given a hint.