Let's move to next exercise how to create generators we already saw in a very simple way. generators in Python are very simple to create. They're exactly similar to function. The only thing different is that it contains one or more yield statements. Now it can have multiple return statement it can have multiple yield statements. But my number of function has a yield statement within it.
It is a generator. And when called a pretender an iterator object, but does not start execution immediately the generator has this unique feature also that it does not start execution immediately. It has to be called every time to produce the output.