Parentheses utility in this if statement

Hi everyone.

I’m curious about what what parentheses are doing in this if statement. Are they there for just readability purpuses?

if(self.get_balance() >= amount):
      return True

    return False

Thank you : ).

If you mean the ones on the outside, then yes, they are for readability or because the person who wrote this is used to other languages which use parens like this (I am for eg).

Yes, I meant the ones on the outside.
Thank you : D.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.