Amazon interview question

Nothing too difficult