Any python programmers?

sahan.cooray

Member
Sep 29, 2015
12
0
0
Hi I'm new to python and experimenting that language. I need to know how to write switch statements in python. The user can select options. I surfed net but I did not get a clear answer.
 

IreshMM

Well-known member
  • Jan 20, 2014
    1,546
    444
    83
    Use if statements.

    If condition:
    #What happens when condition is true
    Else:
    #what happens when false

    U can use multiple conditions using "elif" between "if" and "else"