+ 12

Challenge ::: Jimmy's Phone Call

Description :- Jimmy has to talk to his friends. But he don't know for how many minute he can talk. Task:- You have write a program to calculate how many minute Jimmy can talk if he has (s) amount of balance in his phone. First minute of call cost (min1) Rupees(You can say anything Dollars, as you like for currency unit) and next 9 minutes charges a constant charge of Min2 per minute and after that each minute cost Min3. So you have to calculate.How much Minute Jimmy can talk. Sample Input:- S=20,Min1=3,Min2=1,Min3=2. S=2,Min1=2,Min2=5,Min3=6. Output:- Jimmy can talk for 14 Minutes. Jimmy can talk for 1 Minute. Let's help Jimmy. :)

31st Jan 2018, 2:45 PM
Akash Pal
Akash Pal - avatar
8 Respuestas
31st Jan 2018, 12:42 PM
Gaurav Agrawal
Gaurav Agrawal - avatar
+ 8
https://code.sololearn.com/c38rsbfKMRmb/?ref=app
31st Jan 2018, 12:56 PM
int24h
int24h - avatar
+ 7
@Akash Pal Thanx. I fixed my code.
31st Jan 2018, 2:55 PM
int24h
int24h - avatar
+ 7
Ding Dong..!..Hey Jimmy..!! Who's there..!?... It's Python..🐍😁😉 https://code.sololearn.com/cAdbWasrseDJ/?ref=app
31st Jan 2018, 5:27 PM
Zoetic_Zeel
Zoetic_Zeel - avatar
31st Jan 2018, 4:51 PM
‎ ‏‏‎Anonymous Guy
+ 5
@int24h please update your code please. When I input S=15,min1=3,min2=2,min3=2 The output should be 7 but in your code it outputs 6, which is wrong.So please update it. Edited on 01/02/2018 So you fixed it. Great.
1st Feb 2018, 9:39 AM
Akash Pal
Akash Pal - avatar
1st Feb 2018, 12:34 AM
Med Arezki
Med Arezki - avatar
0
Thanks to all Please help me to be learned c++ programming
1st Feb 2018, 12:37 AM
Aqsa Tabasum
Aqsa Tabasum - avatar