Amazon Interview Question

puzzles