Help Ramu Problem


Please check this code.
according to me, The output in example is given wrong.

hi @vivek21 I think your code is perfectly fine and the example provided is correct too.
could you elaborate on what problem you are facing while solving it ?

Its showing wrong test case

okay i am looking into it …

Hi , In this question you need to calculate the cost separately for each rickshaw in case 2 .Lets say there are two rickshaw Number 2 and Number 5 then it can be that the user opts for unlimited rides in rickshaw number 2 and not in rickshaw number 5 but in your code when you do c2*rnum you consider the case that either he takes unlimited for both rickshaw or none… Because rnum is the total number of unique rickshaws and c2 is the cost of making a rickshaw unlimited … You need to work on a code to do that separately for each rickshaw …Check the comment in my code :- https://ide.codingblocks.com/s/134730