Why only 3 test cases are passing in sololearn's Java section's coding challenge of loan calculator? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 4

Why only 3 test cases are passing in sololearn's Java section's coding challenge of loan calculator?

https://code.sololearn.com/ceGVabcDpnIE/?ref=app

27th Nov 2020, 10:18 AM
Mahima Rajvir Singh
Mahima Rajvir Singh - avatar
3 Answers
+ 2
Mahima Rajvir Singh , try to change line 11 to amount -=(int)Math.ceil(amount*0.1); Also change amount to integer data type.
27th Nov 2020, 10:25 AM
TheWh¡teCat 🇧🇬
TheWh¡teCat 🇧🇬 - avatar
+ 2
TheWh¡teCat 🇧🇬 Thank you so much!! It worked!! 😃😄
27th Nov 2020, 10:31 AM
Mahima Rajvir Singh
Mahima Rajvir Singh - avatar
+ 1
Mahima Rajvir Singh , you are welcome 🐱
27th Nov 2020, 10:31 AM
TheWh¡teCat 🇧🇬
TheWh¡teCat 🇧🇬 - avatar