Sherlock and Cost Discussions | Algorithms | HackerRank
  • + 1 comment

    I'm assuming that you meant :

    1
    5
    100 2 100 2 100
    

    Output for the above should be : 396