Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Why din't MS include Multile inheritance in C#?

Why din't MS include Multile inheritance in C#?

Scheduled Pinned Locked Moved C#
csharpoopquestion
16 Posts 10 Posters 2 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J J4amieC

    Pete O`Hanlon wrote:

    partly because .NET doesn't natively support MI

    Im sure I read recently that the framework does support MI, but the implementation of it raises its own quirks... so they left it out until they decide exactly how it should be implemented. The same article talked about mixins as a possible alternative. Personally I hate both MI and mixins. Sorry I don't have a link to the article, I'll trawl through my history and see if I can find it.

    --- How to get answers to your questions[^]

    B Offline
    B Offline
    Blumen
    wrote on last edited by
    #5

    thanks to all you guys, but what should i tell the interviewer? Possible answers I got by posting this question: 1. Its complex if its implemented 2. More disadvantages than advantages 3. .NET doesnt natively support MI 4. implementing MI creates problems If you were asking me this question in an interview, what answer would you expect Jamie? Regards, Blumen

    J R 2 Replies Last reply
    0
    • B Blumen

      thanks to all you guys, but what should i tell the interviewer? Possible answers I got by posting this question: 1. Its complex if its implemented 2. More disadvantages than advantages 3. .NET doesnt natively support MI 4. implementing MI creates problems If you were asking me this question in an interview, what answer would you expect Jamie? Regards, Blumen

      J Offline
      J Offline
      J4amieC
      wrote on last edited by
      #6

      If I was asking you this question in an interview i'd be an idiot. Not only is it totally irrelevant to day-to-day programming but it sounds as if this guy is either a) A C++ evangelist who is trying to have a bash at c#'s "lack of MI" b) An idiot who has heard a buzzword and is trying to look intelligent. Try asking him why he thinks that MI is relevant to the job and watch him either give a tirade about how wonderful MI is (a) or splutters and changes the subject (b).

      --- How to get answers to your questions[^]

      P L B 3 Replies Last reply
      0
      • J J4amieC

        If I was asking you this question in an interview i'd be an idiot. Not only is it totally irrelevant to day-to-day programming but it sounds as if this guy is either a) A C++ evangelist who is trying to have a bash at c#'s "lack of MI" b) An idiot who has heard a buzzword and is trying to look intelligent. Try asking him why he thinks that MI is relevant to the job and watch him either give a tirade about how wonderful MI is (a) or splutters and changes the subject (b).

        --- How to get answers to your questions[^]

        P Offline
        P Offline
        Pete OHanlon
        wrote on last edited by
        #7

        Amen to that.

        Deja View - the feeling that you've seen this post before.

        1 Reply Last reply
        0
        • B Blumen

          Hi, Why din't Microsoft include Multile inheritance in C#? This was asked to me by an interviewer, I couldn't answer this properly. The guy said there was some reason why they din't include multiple inheritance, which he din't tell me. Regards, Blumen

          RaviBeeR Offline
          RaviBeeR Offline
          RaviBee
          wrote on last edited by
          #8

          blumenhause wrote:

          Why din't Microsoft include Multile inheritance in C#?

          Very likely to ensure that developers don't encounter the diamond problem[^]. /ravi

          This is your brain on Celcius Home | Music | Articles | Freeware | Trips ravib(at)ravib(dot)com

          1 Reply Last reply
          0
          • J J4amieC

            If I was asking you this question in an interview i'd be an idiot. Not only is it totally irrelevant to day-to-day programming but it sounds as if this guy is either a) A C++ evangelist who is trying to have a bash at c#'s "lack of MI" b) An idiot who has heard a buzzword and is trying to look intelligent. Try asking him why he thinks that MI is relevant to the job and watch him either give a tirade about how wonderful MI is (a) or splutters and changes the subject (b).

            --- How to get answers to your questions[^]

            L Offline
            L Offline
            Luc Pattyn
            wrote on last edited by
            #9

            This is a meta-question. At best the people responsible for the C# definition can answer this; everyone else can only guess. Whoever asks this does not intend to be called an idiot, he intends to observe the interviewee's reaction. Not every question is about knowledge... :)

            Luc Pattyn [Forum Guidelines] [My Articles]


            this weeks tips: - make Visual display line numbers: Tools/Options/TextEditor/... - show exceptions with ToString() to see all information - before you ask a question here, search CodeProject, then Google


            1 Reply Last reply
            0
            • B Blumen

              Hi, Why din't Microsoft include Multile inheritance in C#? This was asked to me by an interviewer, I couldn't answer this properly. The guy said there was some reason why they din't include multiple inheritance, which he din't tell me. Regards, Blumen

              P Online
              P Online
              PIEBALDconsult
              wrote on last edited by
              #10

              Hedging their bets; it's easier to add it in later than to remove it. :-D

              1 Reply Last reply
              0
              • B Blumen

                thanks to all you guys, but what should i tell the interviewer? Possible answers I got by posting this question: 1. Its complex if its implemented 2. More disadvantages than advantages 3. .NET doesnt natively support MI 4. implementing MI creates problems If you were asking me this question in an interview, what answer would you expect Jamie? Regards, Blumen

                R Offline
                R Offline
                Rudolf Jan
                wrote on last edited by
                #11

                I think none of the answers is really convincing. Maybe you should answer that we cannot know the motivation of the guys not to include it. Simplicity and avoiding errors might be an argument. On the other hand C# is not a simple language. It includes many complex and new features. If you have the feeling the interviewer is not a fan of multiple inheritance you might say MI is an interesting idea, but you do not really need it in practical situations.

                Rudolf Heijink

                B 1 Reply Last reply
                0
                • J J4amieC

                  If I was asking you this question in an interview i'd be an idiot. Not only is it totally irrelevant to day-to-day programming but it sounds as if this guy is either a) A C++ evangelist who is trying to have a bash at c#'s "lack of MI" b) An idiot who has heard a buzzword and is trying to look intelligent. Try asking him why he thinks that MI is relevant to the job and watch him either give a tirade about how wonderful MI is (a) or splutters and changes the subject (b).

                  --- How to get answers to your questions[^]

                  B Offline
                  B Offline
                  Blumen
                  wrote on last edited by
                  #12

                  :) :) :) May be he was not a idiot afterall, he just din't want me in his team coz they were looking for a person with more experience. hmm, anyway I always feel like asking the interviewer answers to his questions but I back off thinking that most of them don't like to be questioned!

                  1 Reply Last reply
                  0
                  • R Rudolf Jan

                    I think none of the answers is really convincing. Maybe you should answer that we cannot know the motivation of the guys not to include it. Simplicity and avoiding errors might be an argument. On the other hand C# is not a simple language. It includes many complex and new features. If you have the feeling the interviewer is not a fan of multiple inheritance you might say MI is an interesting idea, but you do not really need it in practical situations.

                    Rudolf Heijink

                    B Offline
                    B Offline
                    Blumen
                    wrote on last edited by
                    #13

                    Hi Rudolf, I told him it would make the language complex, but then he started asking "how complex"? I am new to C# and programming as a whole, and I dint know how complex it would make the language. This is my experience in an interview where people don't want to ask you obvious questions. I used to google for interview questions and appear for the interview, but I failed miserably two times. I feel bad when I think about these interviews. I want to dig deep in to topics, but when I start asking why (mostly to Google) something is done this way in .NET framework, rarely do I get good answers (articles/posts). How do you find answers to your questions, how do you get knowledgable? Regards, Blumen

                    S 1 Reply Last reply
                    0
                    • B Blumen

                      Hi Rudolf, I told him it would make the language complex, but then he started asking "how complex"? I am new to C# and programming as a whole, and I dint know how complex it would make the language. This is my experience in an interview where people don't want to ask you obvious questions. I used to google for interview questions and appear for the interview, but I failed miserably two times. I feel bad when I think about these interviews. I want to dig deep in to topics, but when I start asking why (mostly to Google) something is done this way in .NET framework, rarely do I get good answers (articles/posts). How do you find answers to your questions, how do you get knowledgable? Regards, Blumen

                      S Offline
                      S Offline
                      Scott Dorman
                      wrote on last edited by
                      #14

                      blumenhause wrote:

                      How do you find answers to your questions, how do you get knowledgable?

                      There are a lot of different ways:

                      1. Reading books
                      2. On your own investigating - write some code, see what it does and how it behaves
                      3. Using tools like Reflector to see what/how the base class libraries do things
                      4. Ask questions of people that have more experience and/or are more knowlegeable than you on a particular topic.

                      Since you are new to programming and C# (and also, it appears, to technical interviews), the thing to remember is this: There are two types of interviewers: The kind that wants to show off how much he/she knows and the kind that wants to know how much you know and how you react to difficult/challenging questions. The first type of interviewer is difficult to deal with at best as they tend to ask the "impossible" questions and drill into topics that are intentionally hard. The goal is to show you how smart they are and doesn't really help anybody. The second type of interviewer will also ask difficult questions, but the entire interview won't consist of them. This is the person that will ask a mixture of easy to hard questions to try and understand how much you know on a particular topic and what your problem solving skills are. Even after 15 years of experience I have been on interviews where I was asked a question that stumped me. It's always OK to say you don't know rather than trying to guess and get it wrong.

                      Scott.


                      —In just two days, tomorrow will be yesterday. [Forum Guidelines] [Articles] [Blog]

                      B 1 Reply Last reply
                      0
                      • S Scott Dorman

                        blumenhause wrote:

                        How do you find answers to your questions, how do you get knowledgable?

                        There are a lot of different ways:

                        1. Reading books
                        2. On your own investigating - write some code, see what it does and how it behaves
                        3. Using tools like Reflector to see what/how the base class libraries do things
                        4. Ask questions of people that have more experience and/or are more knowlegeable than you on a particular topic.

                        Since you are new to programming and C# (and also, it appears, to technical interviews), the thing to remember is this: There are two types of interviewers: The kind that wants to show off how much he/she knows and the kind that wants to know how much you know and how you react to difficult/challenging questions. The first type of interviewer is difficult to deal with at best as they tend to ask the "impossible" questions and drill into topics that are intentionally hard. The goal is to show you how smart they are and doesn't really help anybody. The second type of interviewer will also ask difficult questions, but the entire interview won't consist of them. This is the person that will ask a mixture of easy to hard questions to try and understand how much you know on a particular topic and what your problem solving skills are. Even after 15 years of experience I have been on interviews where I was asked a question that stumped me. It's always OK to say you don't know rather than trying to guess and get it wrong.

                        Scott.


                        —In just two days, tomorrow will be yesterday. [Forum Guidelines] [Articles] [Blog]

                        B Offline
                        B Offline
                        Blumen
                        wrote on last edited by
                        #15

                        Thank you Scott, that was really informative. Regards, Blumen

                        1 Reply Last reply
                        0
                        • B Blumen

                          Hi, Why din't Microsoft include Multile inheritance in C#? This was asked to me by an interviewer, I couldn't answer this properly. The guy said there was some reason why they din't include multiple inheritance, which he din't tell me. Regards, Blumen

                          E Offline
                          E Offline
                          ednrgc
                          wrote on last edited by
                          #16

                          Because they were making a child language (VB.NET). They didn't want VB programmers to jump from cliffs during the transition into real world programming.

                          1 Reply Last reply
                          0
                          Reply
                          • Reply as topic
                          Log in to reply
                          • Oldest to Newest
                          • Newest to Oldest
                          • Most Votes


                          • Login

                          • Don't have an account? Register

                          • Login or register to search.
                          • First post
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • World
                          • Users
                          • Groups