Explain IEnumerable in C# ( C# Interview Questions)

Поділитися
Вставка
  • Опубліковано 3 жов 2024

КОМЕНТАРІ • 51

  • @questpondvideos
    @questpondvideos  2 роки тому +3

    30 Important C# Interview Questions : ua-cam.com/video/BKynEBPqiIM/v-deo.html
    Software Architecture Interview Questions : ua-cam.com/video/AtTgcbLOqMM/v-deo.html
    20+ Garbage Collection (GC) Interview Questions : ua-cam.com/video/RgfuVp2lXIA/v-deo.html
    25+ OOPS Interview Questions : ua-cam.com/video/u99wAoBjDvQ/v-deo.html
    20+ SQL Server Interview Questions : ua-cam.com/video/SEdAF8mSKS4/v-deo.html
    10+ Power BI Interview Questions : ua-cam.com/video/Cozc9WNBRt4/v-deo.html
    20 MSBI Interview Questions : ua-cam.com/video/Nw_sHEKnOUE/v-deo.html
    SQL Server Joins : ua-cam.com/video/KTvYHEntvn8/v-deo.html
    SQL Step by Step - ua-cam.com/video/uGlfP9o7kmY/v-deo.html
    Angular Step by Step Tutorial for Beginners : ua-cam.com/video/-9VcW7MBDs8/v-deo.html
    25 Angular Interview Questions : ua-cam.com/video/-jeoyDJDsSM/v-deo.html
    25 Important ASP.NET Interview Questions : ua-cam.com/video/pXmMdmJUC0g/v-deo.html
    35 Important JavaScript Interview Questions : ua-cam.com/video/Zb4dPi7CANU/v-deo.html
    20 MySQL Interview Questions : ua-cam.com/video/9hfjC-BpY20/v-deo.html
    5 MSBI Interview Questions : ua-cam.com/video/5E815aXAwYQ/v-deo.html
    20 PHP Interview Questions : ua-cam.com/video/1bpNSynUrl8/v-deo.html

  • @softshells
    @softshells День тому

    My first instinct response is: Objects that implement IEnumerable interface allow us to iterate over them. Furthermore it allows like other Interfaces to develop generic and loosely coupled code.
    Having said this. I learn a lot from your videos 👏. Thanks for sharing and making these public. 👏👏

  • @scotolivera8207
    @scotolivera8207 2 роки тому +4

    thank you sir , it’s bcz of u i am a better c# developer

  • @elliottharrison
    @elliottharrison 2 роки тому +4

    I'm not a fan of this explanation. At 1:29, the reason you can still use your foreach loop on your list even though you haven't explicitly called IEnumerator is because List inherit from IEnumerable. You can see that if you just "right click" and peek definition on List

  • @imadabab
    @imadabab 9 місяців тому

    Nice and real tutorial. Thanks for sharing. I use object generic IEnumerable in the abstract class, and I use a list of myclass in my subclasses.

  • @artmasterio1036
    @artmasterio1036 2 роки тому +4

    Sir, please make video about IEnumerator and Yield. Thank you in advance!

  • @AlgoEasyByArunavaBanerjee
    @AlgoEasyByArunavaBanerjee 2 роки тому +13

    IEnumerable uses iterator pattern

  • @ketankumarsingh6716
    @ketankumarsingh6716 2 роки тому +2

    There might a scenario where we going to implement this pattern to some cases it would be in iterator pattern and in some cases it will be used in a singleton design pattern as well...coz in singleton it acts wrapper + iterator

    • @exogendesign4582
      @exogendesign4582 2 роки тому

      how about data list? people say thiz is faster than using list wrapper? do you know the keyword on how to use this concerning tabular data?

  • @Shreya-ff9dx6fv1s
    @Shreya-ff9dx6fv1s Рік тому +1

    Hi Questpond,
    Sir Please clear this doubt I have done same things what you have done in your code but I Didn't use IEnumerable but still there is no error and I am getting desired output. Then Why to use IEnumerable.
    Please have a Look at these piece of lines.
    using System;
    using System.Collections;
    using System.Collections.Generic;
    namespace HelloWorld
    {
    class Program
    {
    static void Main(string[] args)
    {
    foreach(var temp in get()){
    Console.WriteLine(temp);
    }
    }

    static dynamic get(){
    int a=1;
    var arlist1 = new ArrayList();
    arlist1.Add(1);
    arlist1.Add("Bill");
    arlist1.Add(" ");
    arlist1.Add(true);
    if(a>1)
    return "good";
    else
    return arlist1;
    }
    }
    }
    and getting output :
    1
    Bill

    True

  • @shabiyabanu7990
    @shabiyabanu7990 2 роки тому +2

    Hi sir please explain delegates with some realtime example

  • @nishamaury4026
    @nishamaury4026 2 роки тому

    Simply explain this thank you

  • @saumya9932
    @saumya9932 9 днів тому

    Iterator, Composite, Decorator, and Proxy patterns

  • @shahfaisal3923
    @shahfaisal3923 2 роки тому

    great video Sir.

  • @amamsharma372
    @amamsharma372 2 роки тому

    Very helpful 👍

  • @niteshchaurasia1332
    @niteshchaurasia1332 2 роки тому +2

    Sir, I am confuse between Thread and Async Await.. plz make a video on them

    • @carmelraj2158
      @carmelraj2158 2 роки тому +4

      Async methods are intended to be non-blocking operations, it doesn't create new thread whereas Thread creates new thread and runs at the same time (concurrently) on different CPU core on the system.

    • @abhikarne
      @abhikarne 2 роки тому

      @@carmelraj2158 what about TPL

    • @questpondvideos
      @questpondvideos  2 роки тому +3

      @Carmel raj is right. If you want understand that sentence practically check this video , its one of our best creations ua-cam.com/video/G3tz9rxts8E/v-deo.html

    • @niteshchaurasia1332
      @niteshchaurasia1332 2 роки тому

      @@questpondvideos thank you Sir

  • @CodeSample360
    @CodeSample360 3 місяці тому

    Your question's answer is that - IEnumerable uses an Iterator design pattern.
    Thank you.

  • @hemantkumawat9173
    @hemantkumawat9173 Рік тому

    Great

  • @amamsharma372
    @amamsharma372 2 роки тому

    Keep uploading

  • @srinubathina9096
    @srinubathina9096 2 роки тому +2

    Iterator pattern

  • @jerinpalissery4797
    @jerinpalissery4797 2 роки тому

    What is the difference between first() and firstordefualt()

    • @thiru2175
      @thiru2175 Рік тому +1

      FirstorDefault() => handles the null values from the results in a list
      First() => doesn't handle the null values, means it throws the null reference exception if the list doesn't contains a record with the given criteria

  • @wewtrtr
    @wewtrtr 2 роки тому

    Shared

  • @ShamimShaikhAM
    @ShamimShaikhAM 2 роки тому +1

    IEnumerable uses Iterator design pattern

  • @Anuj_sk
    @Anuj_sk 2 місяці тому

    Can you explain sir ...runtime polymorphism

  • @barwalgayatri4655
    @barwalgayatri4655 Рік тому

    Answer is - Iterator Design Pattern

  • @udhayakumar-i1k
    @udhayakumar-i1k Рік тому

    @4:00

  • @udayshastri5288
    @udayshastri5288 2 дні тому

    Iterator

  • @trijay
    @trijay 7 місяців тому

    Behavioral Iterator Pattern

  • @kapilagarwal3887
    @kapilagarwal3887 2 роки тому

    Iterator Pattern

  • @exogendesign4582
    @exogendesign4582 2 роки тому +1

    You're jumping from everywhere focus only on one thing. Another thing is explain it first technically not by your own terms then proceed the explanation just explaining that part. I understand nothing as its really vague you keep jumping to list then Interview Question etc. There's no point in learning how to answer a Question when one doesn't understand the core concept of the Answer. Memorizing and understanding the concept are two different thing. You're teaching somebody to become a Robot instead of a Thinker this ain't India.

    • @questpondvideos
      @questpondvideos  2 роки тому

      So did not i talk about the core concept, Did not i demonstrate code . you still this is robot explanation , can you explain what is missed here so that i can also learn. Happy learning.

    • @exogendesign4582
      @exogendesign4582 2 роки тому

      @@questpondvideos I am not hating as clearly you are expert in c#. But people like me who are literally stupid and skeptical needs an explanation that supports technical. I can't fully grasp it coz you didn't go in it on depth but its okay I get it now after banging my head on how to use it properly on mvvm concept.

    • @questpondvideos
      @questpondvideos  2 роки тому

      @@exogendesign4582 you should start with basic learn c# and then start with this video ua-cam.com/video/AxEGRBFwlmI/v-deo.html

  • @sumitsingh-dp7ue
    @sumitsingh-dp7ue 2 роки тому

    Factory pattern

  • @itsniks8782
    @itsniks8782 Рік тому

    sir please dont west time on other talk you have create 8 min video and 4 min you have waste on other talk so please

  • @stutiagarwal7057
    @stutiagarwal7057 5 місяців тому

    IEnumerable/IEnumerator implement Iterator Pattern @Questpond

  • @kamdemkakengne
    @kamdemkakengne 2 роки тому +1

    Iterator pattern

  • @seanishok04
    @seanishok04 2 роки тому +1

    IEnumerable uses Iterator pattern

  • @sudhansusekharsatapathy8908
    @sudhansusekharsatapathy8908 4 місяці тому

    Iterator

  • @artak9439
    @artak9439 2 роки тому +1

    Iterator pattern

  • @techinfo6896
    @techinfo6896 2 роки тому +1

    Iterator pattern

  • @kaleemiqbal4190
    @kaleemiqbal4190 Місяць тому

    Iterator pattern

  • @chandrashekhargupta4377
    @chandrashekhargupta4377 6 місяців тому

    Iterator pattern

  • @harshithaharshi1175
    @harshithaharshi1175 Рік тому

    Repository pattern