Pergunta de entrevista da empresa FIS

SQl queries which was a little tough