Click here to Skip to main content
Click here to Skip to main content
Add your own
alternative version

Pick Your Enumerator & Me.Understand Yield and IEnumerable (C#)

, 21 Apr 2013 CPOL
Using multiple enumerators and implementing IEnumerable with Yield or IEnumerator.



Compare Revision Minor Date Status Editor
11 No 21-Apr-13 15:32 Pending Mike-MadBadger
Version 5 (21 April 2013): Fixed issue with test for var == double.NaN, should have been double.IsNaN(var); added section on 'foreach == while (MoveNext()) + Current' further typographical errors fixe
9 No 13-Apr-13 4:02 Pending Mike-MadBadger
Updates in content.
7 No 12-Apr-13 2:00 Pending Mike-MadBadger
Updates in content.
6 No 11-Apr-13 19:13 Available Smitha Vijayan
Updates in content.
5 No 11-Apr-13 17:56 Pending Mike-MadBadger
Updates in content. 10209 changes had been made.
3 No 8-Apr-13 2:32 Pending Mike-MadBadger
Source and Demo links
2 No 7-Apr-13 16:12 Composing Mike-MadBadger
Updates in content. 14 changes had been made.
1 No 7-Apr-13 13:02 Composing Mike-MadBadger
Initial creation


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

France France
A hobbyist begin-again-er!
Spent a few years longer ago than I care to remember with BBC Basic, a couple of years with Delphi about 10-15 years ago with a smattering af MS Access applications along the way. Dropped out of it completely except for the occasional Excel macro.
Finally picked up the baton again with VB.Net in VS2010 and now VS 2012and have been playing around quite a bit with a few odds and sodds, learning much as I go - and long may it continue.
I don't work even close to the IT industry and probably never will, but I do enjoy it as a hobby.

| Advertise | Privacy | Mobile
Web04 | 2.8.141015.1 | Last Updated 21 Apr 2013
Article Copyright 2013 by Mike-MadBadger
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid