Abstract: This sample shows how to create a list class that implements IEnumerable and the yield keyword to enable foreach iteration over the contents of the list. Two properties are defined, one returning the odd numbers, the other returning the even numbers.