Morgan Stanley interview question

1 leetcode question per interview, and 1 SQL question