0

Whats the problem in my logic

I have tried to solve hovercraft problem in code coach.it shows two test cases are failed out of five.can anybody explain a perfect logic for this customers=int(input()) insurance=1000000 buildcost=2000000 sellcost=3000000 if((buildcost * customers)+insurance)<sellcost* customers: print("Profit") elif((buildcost * customers)+insurance)>sellcost* customers: print("Loss") else: print("Broke Even")

8th Feb 2021, 9:13 AM
Guraja Teja Surya Lokesh Kumar
Guraja Teja Surya Lokesh Kumar - avatar
2 Antworten
+ 8
Based on the problem, within a month, there are 10 hovercrafts made, so instead of multiplying the buildcost by costumers (number of orders), multiply it by 10. https://code.sololearn.com/cEY2JgHwfJ3o/?ref=app
8th Feb 2021, 9:26 AM
noteve
noteve - avatar
+ 2
Thanks a lot Cyan sir
8th Feb 2021, 9:29 AM
Guraja Teja Surya Lokesh Kumar
Guraja Teja Surya Lokesh Kumar - avatar