Pergunta de entrevista da empresa Glassdoor

Question related with self join in sql