Pergunta de entrevista da empresa Solution Street

Database query with JOIN, coding question