Intermediate
C#
Q42 / 100
What is the IEnumerable<T> interface and yield return?
Correct! Well done.
Incorrect.
The correct answer is B) IEnumerable<T> supports forward-only iteration. yield return creates an iterator method that lazily generates values one at a time
B
Correct Answer
IEnumerable<T> supports forward-only iteration. yield return creates an iterator method that lazily generates values one at a time
Explanation
Iterator methods using yield return produce values on-demand as the consumer iterates, enabling memory-efficient pipelines.
Progress
42/100