Tableau Software interview question

NDA cannot reveal .. it was leetcode medium problem