If statement in python

#1

I am a beginner in python can anyone say why if statement is not working

#2

@dineshsubramani you need to indent your code after the “:”

https://docs.python.org/3/tutorial/controlflow.html

1 Like
#3

num = IN[0]

the line after if , use 4 spaces and start

1 Like
#4

Thank a lot khuzaimah

1 Like
#5

You should have an indent / Tab in the next line of IF
image

1 Like
#6

Learn more about…Python If statement

1 Like