[Solved] How can I pass a variable from one generator to another in Python?

[ad_1]

I am not completly sure if this is what you are looking for, but generators have a method called ‘send’ which enables you to pass data to the generator.
You might want to read this example. Pay attention to the functions ‘consume’ and ‘produce’.

[ad_2]

solved How can I pass a variable from one generator to another in Python?