Can we have sections of codes and can jump while execution?
Asked by
Farooq Pathan
Guys,
I need to know if there is any way to create sections of code and to jump while execution
#generate random section to execute
import random
random.seed()
section_to_execute = random.randint(1, 3)
#go to that section
goto section_to_execute
#now here is the code of all sections
#section1
popup("you are in section 1 code")
#section2
popup("you are in section 2 code")
#section3
popup("you are in section 3 code")
So is it possible to select section which we need to execute from a random variable, and only that section should be executed all other code should be skipped.
Question information
- Language:
- English Edit question
- Status:
- Answered
- For:
- SikuliX Edit question
- Assignee:
- No assignee Edit question
- Last query:
- Last reply:
Can you help with this problem?
Provide an answer of your own, or ask Farooq Pathan for more information if necessary.
To post a message you must log in.