Pergunta de entrevista da empresa Amazon

Write SQL to Find groups having exactly three different tags.