Pregunta de entrevista de Thermo Fisher Scientific

SQL question - can use any dialect to solve