Yield error in generators

Hello @adityakathoch_a87e00c5c7e39b2d,
yeild keyword is used to create a generator function.
And you are not using inside the function and using inside the class it will be used inside the function like return keyword.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.