BuyHatke interview question

Matrix chain multiplication implementation