Im not able to understand whats wrong in my code

it is showing me 10.25 as my output in jupyter notebook
when i submitted answer ,it is showing me ,10.0
why comma came, , ???


why is my value changed ???

please help me,

Hi @Sekhar_Rajanala Please ignore the comma. It has nothing to do with your output. Your output is perfectly fine as it should be. We are working on a fix for the comma display and soon it will be fixed.

Feel free to shoot any more questions if you have any. Happy learning!

when i submitted answer , it is not taking

@Sekhar_Rajanala Please check the output for round(compund_interest(100, 5, 2), 2)

same error

@Sekhar_Rajanala Yes, as you can see, your code is expected to return 10.25 but your code is returning 10.0

If you are still stuck, you can see the hint by clicking on Get Hint

Hope that helps. Happy learning!

not working

Hi @Sekhar_Rajanala ,
I don’t know how this code is outputting as 10.25.
Because this must be giving 5.0 as shown in the 'result from your code tab '.
I have pointed out two errors in your code

Hint:

  1. You are calculating and returning the comp_interest in loop.

  2. You’re subtracting 100 from principle while calculating comp_interest which won’t give desired output for any other value of principle.

All the Best :slightly_smiling_face: :+1: