Amazon interview question

a graph question with islands