Concepts Simplified #4: Yield Keyword

preview_player
Показать описание
This is a quick video attempting to explain , briefly, what Yield statement is and what does it do exactly.

The yield statement is only used when defining a generator function.
Using a yield statement in a function definition is sufficient to cause that definition to create a generator function instead of a normal function.

Рекомендации по теме
Комментарии
Автор

Thank you so much....

The term yield and generator used to intimidate me a lot....you just helped me out of one of my phobias in a matter of mins

theanonymous
Автор

do you remember the first program you wrote in your life ?

ahmedqassem