• Visitors can check out the Forum FAQ by clicking this link. You have to register before you can post: click the REGISTER link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. View our Forum Privacy Policy.
  • Want to receive the latest contracting news and advice straight to your inbox? Sign up to the ContractorUK newsletter here. Every sign up will also be entered into a draw to WIN £100 Amazon vouchers!

C# interview question

Collapse
X
  •  
  • Filter
  • Time
  • Show
Clear All
new posts

    #31
    Originally posted by adubya View Post
    Then again, if you're going in an interview for a C# programming gig and someone starts banging on about relaying to stakeholders one might wonder "WTF?".
    Fair enough point - but in this market many 'opportunities' are involving start-ups with venture capital / companies that simply do not understand even the basics of IT. And so we are expected to provide them with not only delivered software, but advice on infrastructure, training of users, business decisions; they have a vague idea of what they want, and they throw it over the fence and expect us to sort out their mess.

    A contractor doesn't have to accept that kind of role, but it can be quite lucrative if you manage the client correctly.

    Just my personal experience.


    Regarding the original discussion point - I have to go with readability, stability and maintability of code over (IMHO) what would be marginal performance gains. If performance of that particular operation was business critical (I cannot come up with an example myself), then you would probably start with looking at which language was the optimal. Otherwise its probably going to cost more time and effort over the lifetime of the software to maintain, test and debug than the perceived gains of using the more esoteric aspects of the language. Profiling the application would most likely reveal the usual suspects in terms of performance hits - and that code is unlikely to be in the top 1%.
    Vieze Oude Man

    Comment


      #32
      Originally posted by Durbs View Post
      I'd guess the kind of person who can recite the bumper book of C would struggle with the latter kind of interview.
      It's knowing this sort of stuff that is the difference between and expert and a journeyman. As an interviewer if you present someone with a question like this and they can't answer it you know that they have gaps in their knowledge.

      Arguments that you would never use this particular piece of code because there are library functions for x, y and z miss the rather important point that someone who doesn't know the basic operators, even the more obscure ones, is unlikely to know the standard library inside out either.
      While you're waiting, read the free novel we sent you. It's a Spanish story about a guy named 'Manual.'

      Comment


        #33
        Originally posted by doodab View Post
        It's knowing this sort of stuff that is the difference between and expert and a journeyman. As an interviewer if you present someone with a question like this and they can't answer it you know that they have gaps in their knowledge.

        Arguments that you would never use this particular piece of code because there are library functions for x, y and z miss the rather important point that someone who doesn't know the basic operators, even the more obscure ones, is unlikely to know the standard library inside out either.

        Have to disagree with parts of that - basic operators, yes, of course... but expecting encylopedic knowledge of the whole library of functions - and for example which version they are supported in (2, 3, 3.5, 4, WP7, WP 7.5, Azure, partial trust, deprecated, etc etc), is not the most immediately useful skill.

        I am in a position where sometimes I contract on projects for clients, and sometimes I hire contractors to work for my company to supply clients with software. When hiring, I would personally look for examples of understanding of a problem - a requirement - that needs to be implemented, and the persons approach to solving that problem.

        The actual implementation will typically go through several phases - the delivery time is always 'yesterday', often while the client is still deciding what they actually need delivered. So some indication of a pragmatic approach is key. The optimisation phases are sometimes deemed a luxury by the client, but that is also sometimes the reality of business; and I guess my view is that we need to combine an understanding of software, with an understanding of our clients view of the world. It does not mean that we cannot be professional - but in my view those sort of interview questions (as mentioned by OP) are only asked by insecure people who are trying to protect their leech status at a client who does not understand software development.

        Finished a project a month ago, where my company was supplying services of two people, and Microsoft and Avanade were involved - they thought it was worth sponsoring, advertising etc, but the client couldn't actually describe what they wanted. It's still going, but that fundamental lack of definition and understanding between business and technical made everything else irrelevant. Maybe in a year or two, someone will be arguing over which method call is faster - if the client survives as a business. But by that time, more functions in .Net will be deprecated (anyone gone MVC / WCF and confused about Web API.. Silverlight.. Metro...?), new options will be available.. but the underlying skills of analysing a problem and looking for the best available solution will still be valid.
        Last edited by mcquiggd; 29 July 2012, 11:38. Reason: Clarification re: original posters question
        Vieze Oude Man

        Comment


          #34
          Originally posted by russell View Post
          If you claim to be a computer programmer and don't understand basic binary operations then you are an embarrassment to the profession.
          You are a cock jockey but i'll rise to bait anyway. Your comment, although obviously just written to get a rise, shows a real blinkered view of how software is delivered these days and what the role of a development contractor can be.

          I dont claim to be a 'computer programmer', I'm a 'software developer', a provider of 'solutions', theres a difference. I guess like a lot of people these days, I need to spread myself very thin and be a jack of all trades. I may be working on a C# MVC app then move onto a VB web forms app, then a WCF app, then a ye olde traditional SOAP web service, then an iPhone app, churning out UML or even occasionally knocking up pretty pictures in Photoshop.

          I can, and do, design, build and deliver top notch solutions using all these and much more. I emphasise delivering a solution here, not a particular component part. If specialist knowledge of multiplying things by 16 is required then i'll request that resource and i'm not arrogant enough to attempt to deliver something that I feel would be better suited to another resource.

          As people have said "if you're going in an interview for a C# programming gig and someone starts banging on about relaying to stakeholders one might wonder "WTF?" then I assume we are talking about very different roles to the ones I generally fill. Do I have gaps in my knowledge for the technologies I stated? Hell, yes I do but I get the roles I do due to the breadth of my knowledge and I can EVEN talk to the client too! Not like the C developer who has to be hidden whenever they visit in case he licks one of them.
          Last edited by Durbs; 29 July 2012, 11:47.

          Comment


            #35
            Originally posted by Durbs View Post
            You are a cock jockey but i'll rise to bait anyway. Your comment, although obviously just written to get a rise, shows a real blinkered view of how software is delivered these days and what the role of a development contractor can be.

            I dont claim to be a 'computer programmer', I'm a 'software developer', a provider of 'solutions', theres a difference. I guess like a lot of people these days, I need to spread myself very thin and be a jack of all trades. I may be working on a C# MVC app then move onto a VB web forms app, then a WCF app, then a ye olde traditional SOAP web service, then an iPhone app, churning out UML or even occasionally knocking up pretty pictures in Photoshop.

            I can, and do, design, build and deliver top notch solutions using all these and much more. I emphasise delivering a solution here, not a particular component part. If specialist knowledge of multiplying things by 16 is required then i'll request that resource and i'm not arrogant enough to attempt to deliver something that I feel would be better suited to another resource.

            As people have said "if you're going in an interview for a C# programming gig and someone starts banging on about relaying to stakeholders one might wonder "WTF?" then I assume we are talking about very different roles to the ones I generally fill. Do I have gaps in my knowledge for the technologies I stated? Hell, yes I do but I get the roles I do due to the breadth of my knowledge and I can EVEN talk to the client too! Not like the C developer who has to be hidden whenever they visit in case he licks one of them.
            I was winding you up, Jeez.
            Last edited by russell; 29 July 2012, 13:27.

            Comment


              #36
              Originally posted by russell View Post
              I was winding you up, Jeez.
              You succeeded

              Comment


                #37
                Originally posted by russell View Post
                I was winding you up, Jeez.
                I know, sorry, I broke my rule of never ranting on the internet or getting involved in forum squabbles so you have my apologies for the cock jockey thing.

                Comment


                  #38
                  Originally posted by Jaws View Post
                  I have used the bit shift operator before in order to extract red/green/blue values which if I remember correctly are stored as a 32 bit values in windows. Beyond that never.
                  Last time I used it was to get the bit value of a particular position within a byte. Something like:

                  Code:
                  char my_byte=0;
                  
                  /** stuff that sets my_byte **/
                  
                  int is_set(int position)
                  {
                      return my_byte & 1<<position;
                  }
                  I had this come up in an interview for a C/C++ role a few months ago.

                  Comment


                    #39
                    Blimey... I can't believe a discussion about the bit shift operator has run to 4 pages.

                    It is a basic (as in elementary, not BASIC) technique that's been around for year. I'm not posting this to wind people up (although I suppose it will) but TBH if you're not at least aware of it (evenif you don't use it) shows a lack of depth in your programming skills.

                    For the record, I don't just hack code, I regard myself as a software engineer with (too many years) in the industry involved in full software life cycle.

                    Anyway... bring on the whinging and school yard insults from the script kiddies....
                    Do what thou wilt

                    Comment


                      #40
                      Originally posted by Dark Black View Post
                      It is a basic (as in elementary, not BASIC) technique that's been around for year. I'm not posting this to wind people up (although I suppose it will) but TBH if you're not at least aware of it (evenif you don't use it) shows a lack of depth in your programming skills.
                      I completely agree. We're not talking about knowing the entire .NET Framework from memory here, the bit shift is an operator and let's be honest, there aren't so many of them in C# that a developer shouldn't at least be aware of them all, regardless of if, or when, you'd actually use one in practice.

                      I do agree though that any programmer who knowingly used this to do something as stupid as multiply a value by 16 should be shot for writing intentionally obtuse code but what we're talking about here is whether an experienced c# developer should, under test conditions, be able to identify and describe the purpose of said operator, not whether its existence in the language is justified (which it definitely is because it does serve a legitimate purpose as others have described).

                      Comment

                      Working...
                      X