HARMAN Interview Question

Sql query