Mirchi Interview Question

recursive cte, cte , window function