Credit Karma interview question

topological sorting