Amazon Interview Question

SQL Join , group by questions Live coding.