+ 1
What are the difference between (yield) & (return) statement? I can't understand.
Can anyone help me with it? Please provide answer with example so that I can understand clearly. Thanks in advance.
2 Answers
+ 7
You can read from these threads already created.
https://www.sololearn.com/Discuss/737308/?ref=app
https://www.sololearn.com/Discuss/1046632/?ref=app
+ 2
In case of Yield , Program avoid it's repeatition from the beginning for every time , second time it starts from return