InfoCepts Interview Question

Sql question using distinct .