Pregunta de entrevista de Servosys Solutions

sql join, and one logical tricky question