BlackRock interview question

use python to solve problem and give video