Rakuten Interview Question

SQL: normal join, window function