Capital One Interview Question

SQL questions based on a scenario