What is the difference between IEnumerable and Foreach loop
Can anyone explain me the difference between the both, when should I use IEnumerable and Foreach loop, as both are used for looping the collections.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Amit GuptaRank #190 · 12.8K reputationPosted Aug 5, 2017, 8:31 AM EDT
Khaja MoizuddinRank #270 · 9.4K reputationPosted Aug 6, 2017, 3:21 AM EDT
Amit GuptaRank #190 · 12.8K reputationPosted Aug 6, 2017, 7:52 AM EDT
Gokhul VarmanRank #1,505 · 1.1K reputationPosted Aug 6, 2017, 8:24 AM EDT
Sundaram SubramanianRank #150 · 15.2K reputationPosted Aug 6, 2017, 5:16 PM EDT
Gnanavel SekarRank #333 · 7.5K reputationPosted Aug 6, 2017, 5:33 PM EDT
Saravanan PonnusamyRank #634 · 3.8K reputationPosted Aug 7, 2017, 9:38 PM EDT
Khaja MoizuddinRank #270 · 9.4K reputationPosted Aug 8, 2017, 8:43 AM EDT
Nitin SontakkeRank #264 · 9.6K reputationPosted Aug 23, 2017, 9:28 PM EDT