Syntax Of Nested If Statement In Python