Write SQL to compute max-overlap lists | Pinterest SQL Question