Amazon interview question

1 Problem solving hard leetcode question and LP