RBC Interview Question

Don't remember the exact question. but had to use window function for the sql query