Have you ever felt anger, because you have to write in soy languages, not chad c?
Now you can cope with it, introducing
goto
syntax in Python programming language:
from goto import *;
@label
def init():
global i;
i = 0;
@label
def loop():
global i;
print("%d: Hello, World!" % i);
i = i + 1;
goto("loop", i <= 10);
@label
def end():
print("Done!");
For motivation see ./motivation.md
.
For examples see ./example-complex-loop.py
,
./example-example-nonexistent-label.py
.
Thanks @Tsoding for inspiration: 'I implemented Goto in OCaml' video.
For real-world use consider other implementations of goto in Python:
- python-goto by snoack,
- goto for Python by Richie Hindle.