Explain Generics in C# ? When and why to use them ?

Поделиться
HTML-код
  • Опубликовано: 20 июн 2022
  • 1. Full .NET Interview Course
    C# / ASP.NET Core / MVC / API - Top 500 Interview Questions
    www.udemy.com/course/csharp-o...
    Don't worry if course not helping you, Udemy has 30 days Free Refund Policy.
    2. Quick Revision Book (PDF format)
    Top 500 .NET Interview Questions - OOPS/ C#/ ASP.Net/ MVC/ SQL /.Net Core /Web API
    imojo.in/interviewhappy
    50% Discount Applied on above link.
    Don't worry if book not helping you, I will return 100% of your money with in 7 days of purchase. Just mail me at anuragrawat123@gmail.com.
    My best wishes are with you.

Комментарии • 35

  • @nithin-j2e
    @nithin-j2e 6 дней назад

    simple and straight

  • @sribardhansimhadri3613
    @sribardhansimhadri3613 2 года назад +1

    Very Nice Explanation

  • @manieditz3012
    @manieditz3012 7 месяцев назад

    Thank you sir

  • @lakshmisony8803
    @lakshmisony8803 12 дней назад

    So in generic class we have to define static class only.is'tit?

  • @danielroma2370
    @danielroma2370 Год назад +1

    Good explanation, thank you!

  • @vinaybammidi7123
    @vinaybammidi7123 Год назад +1

    Thank you. Very useful. Generic are necessary.

  • @KIRANKUMAR-mn6rw
    @KIRANKUMAR-mn6rw Год назад +2

    how do equate class using generics?
    say u have class A with set of properties and class B with other set of properties so now how do u compare?

    • @interviewhappy
      @interviewhappy  Год назад

      Hi Kiran, I think object.Equals and with generics this IEquatable will do what you are asking.

  • @sahaksargsyan7397
    @sahaksargsyan7397 8 месяцев назад

    Hello Happy, it will be nice, if you make video about inheritance from generic class. Thank you

  • @rajumechanicalhub5805
    @rajumechanicalhub5805 8 месяцев назад

    Tq sir

  • @imadabab
    @imadabab Год назад

    Good explanation. Thanks.

  • @leelanp
    @leelanp 2 года назад +1

    good explanation

  • @kaniyansai
    @kaniyansai 8 месяцев назад

    Very very useful

  • @ssmcs060
    @ssmcs060 2 года назад +2

    Apart from object, cant we use method overloading?

    • @interviewhappy
      @interviewhappy  2 года назад +2

      Yes Sampat you are right, but then you have to write more lines of code for new overloaded methods which is a overhead then.

    • @ssmcs060
      @ssmcs060 2 года назад +1

      @@interviewhappy hummmm. I was also started thinking this lately. If 2 such methods exist then results in 4 methods.

  • @prabhatkumar353
    @prabhatkumar353 10 месяцев назад

    Thanku sir Nice explanation

  • @Khushi-FoodPlaza
    @Khushi-FoodPlaza 3 месяца назад

    Please make video on array 😢real time projects pls

  • @deepakgupta5733
    @deepakgupta5733 Год назад +1

    What does generics internally use?

    • @interviewhappy
      @interviewhappy  Год назад

      Good question Deepak. I will get back on this and if you know, then you can share.

  • @shreedharrs9540
    @shreedharrs9540 10 месяцев назад +1

    Pls make a video of framework automation it is helpful every one pls do it asap

    • @interviewhappy
      @interviewhappy  10 месяцев назад

      Sure, I will try, but it might take some time. All the best.

  • @madhavikiran6920
    @madhavikiran6920 Год назад +2

    Can you make video on Generic collection?

  • @bandarapurajashekarreddy1692
    @bandarapurajashekarreddy1692 Год назад +1

    Please do video on Reflection in c#

  • @poojachavan396
    @poojachavan396 11 месяцев назад

    Can you make video on Entity framework core interview questions?

    • @interviewhappy
      @interviewhappy  11 месяцев назад

      I added some questions of EF but not all. May be in future I will add them.

  • @vipulshrivastava1069
    @vipulshrivastava1069 4 месяца назад

    Set video paly speed to 1.25