Last answered:

04 Mar 2023

Posted on:

03 Mar 2023

0

Resolved: Misunderstanding

Could you please explain how the 15 >= 10 + 10  gives False ??

3 answers ( 1 marked as helpful)
Instructor
Posted on:

03 Mar 2023

0

Hi Girish!


Thanks for reaching out.


The order in which Python prioritizes the arithmetic operations plays a role here.

First, it applies the addition operation (i.e. 10 + 10), then it compares the values (15 vs 20). Since 15 is neither greater than nor equal to 20, you obtain False.


Hope this helps.
Kind regards,
Martin

Posted on:

04 Mar 2023

0

Hello Martin,

Good Evening,

Thank you very much for the clarification of my doubt.


Thanks and Regards,

Girish Rane

Instructor
Posted on:

04 Mar 2023

0

Hi Girish!

You are very welcome.


Kind regards,
Martin

Submit an answer

related questions