Interviews3 answers
What is the Difference between IEnumerable and IEnumerator
3 Answers
Please refer to the following URL to know the differences between IEnumerable and IEnumerator,
http://onlydifferencefaqs.blogspot.in/2012/07/dotnet-programming-concepts-difference.html
Umar AliPosted Sep 1, 2012, 10:06 AM EDT
An IEnumerator is a thing that can enumerate: it has the MoveNext, Current, and Reset methods (which in .NET code you probably won't call explicitly, though you could).
An IEnumerable is a thing that can be enumerated...which simply means that it has a GetEnumerator method that returns an IEnumerator.
kalit sikkaPosted Sep 18, 2009, 2:11 AM EDT
IEnumerable have one method GetEnumerator()
IEnumerator have one Property current and two methods Reset and MoveNext
IEnumerator have one Property current and two methods Reset and MoveNext
mukund LahanePosted Sep 17, 2009, 3:10 AM EDT