Actually, maybe it’s better if you see what I want to do because I’m not sure if I’m framing the problem/title correctly.
My aim is something like a State Machine. The example below is basic circular diagram where: f -> g, and g -> f.
def f(): return g() def g(): return f() f()
I want to process f(), be done with it, and then go to g(). Nevermind the fact this goes on forever. I might be interested in carrying arguments to g(), but I don’t need to keep the stack of function calls and var states as in Recursion.
submitted by /u/R717159631668645
[link] [comments]
r/learnpython Actually, maybe it’s better if you see what I want to do because I’m not sure if I’m framing the problem/title correctly. My aim is something like a State Machine. The example below is basic circular diagram where: f -> g, and g -> f. def f(): return g() def g(): return f() f() I want to process f(), be done with it, and then go to g(). Nevermind the fact this goes on forever. I might be interested in carrying arguments to g(), but I don’t need to keep the stack of function calls and var states as in Recursion. submitted by /u/R717159631668645 [link] [comments]
Actually, maybe it’s better if you see what I want to do because I’m not sure if I’m framing the problem/title correctly.
My aim is something like a State Machine. The example below is basic circular diagram where: f -> g, and g -> f.
def f(): return g() def g(): return f() f()
I want to process f(), be done with it, and then go to g(). Nevermind the fact this goes on forever. I might be interested in carrying arguments to g(), but I don’t need to keep the stack of function calls and var states as in Recursion.
submitted by /u/R717159631668645
[link] [comments]