Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
This thread reeks of elitism and of developers from vastly different platforms misunderstanding each other.
What is very different than what? I'm not sure what you're comparing. Meanwhile, the techniques for reversing a linked or traversing a binary tree haven't changed in a couple decades.ahhhhh. you're talking about software engineers. I think that is very different... it's the technology, it's just moving way too fast. not a single university is up to date.
Sorry -- what is it that happens? What is usually a management screw-up?yeah that happens. but that is usually a management screw up. employees being treated poorly etc
If an employee leaves after we have invested heavily in them, then we're at a loss.
mikeblas said:techniques for reversing a linked or traversing a binary tree haven't changed in a couple decades.
We have a super-low voluntary turnover rate, so there's no "management screw-ups". The problem is instead of betting on the employee's proven track record, you're suggesting we bet on their future ability to learn and perform and continue to grow. That makes hiring far more difficult -- predicting future performance with no track record and no ability to demonstrate skills in an interview setting is lots harder than predicting future performance with a track record and the ability to show those skills.this is usually a management screw up. not paying them their worth, not giving them position advances, treating them poorly.
We're not trying to hire fresh out of college for any discipline. We're not asking about things that have recently changed or are new techniques -- simple memory allocation questions and managing data structures are techniques that have existed for twenty years in the C and C++ communities.I'm not sure what type of software you guys are talking about but in web development or design the technology is simply moving too fast to expect a new hire out of college to have anything but basic understandings, just the sad truth.
When you ask questions like "how do you traverse a binary tree" are you asking them for every precise step in C++ or are you just looking to see that they know the gist of it all?
Exactly how many potential hires do not end up qualify? The pickings are definitely slim...
to answer the original question. I think you need to find someone that is smart and able to learn, do some aptitude and problem solving skill tests and then spend 3-4 years or more training until they are able to contribute significantly. That is what my father has been doing and it's worked out very well. His senior engineers get paid a shitload though, 200k+.... only 5% or so get hired from what my dad has told me..
personally I'm not sure an engineer today is any less competent than an engineer from 10-20 years ago. It's just a much more complex world now
Societal pressures and ethical breaches are not mutually exclusive; clearly in the case I posted they were both necessary components in what transpired. Saying that moral breaches *can* occur in all societies doesn't speak at all to their frequency or the factors that motivate them.I don't think societal pressures have much to do with that anecdote; people who can't tell right from wrong exist in all societies.
I suppose I meant North America. I am not from the US. I think our countries rank fairly comparably on these measures and have similar education systems given my conversations with friends and coworkers.I guess, though, by "we" you mean The United States. If so, it's pretty clear that something needs to be done as the US lags most other first-world countries in science and math competency as well as engineering graduates.
I'm just terribly frustrated with people who claim to be developers, but can't code. It's really not a unique problem -- my experience is echoed by many others
you may not find a C++ god
Yeah I have a hard time believing that, this is at the very basic end of loops and applying logic. Anybody who is doing a computing degree who can't do that should really just stop and reassess their options.i was actually talking about electrical engineers when I said that, didn't see yall were talking about software, my bad!
but yeah it's very scary if someone with a comp sci degree can't solve fizzbuzz in under a minute
We already do.Perhaps you should broaden your search parameters... go head hunt at Google/Amazon/Apple.
We'd expect a competent developer to be a permanent hire.Sure, you may not find a C++ god, but a competent developer should be able to catch on within 1-2 months. If not, just fire them within their 90 day probationary period.
Yes, I work at Valve. You might try problems from this post, or think about some of the problems identified in this list. The first list has a few other interesting problems in the thread where it lives. Note, though, that we don't hire entry-level employees -- we don't consider CS grads right out of college, normally, unless they have exemplary work that has received wide acclaim.mikeblas, I wanna see just how high your expectations are of computer science grads right out of college. Come up with an assignment that should take an hour to code from scratch, I wanna see if I can do it lol. Btw, you work at Valve correct?
We're asking for working C or C++ code. We're not sticklers about syntax; we don't chase people out of the room for a missing semicolon. Someone who's an experienced C or C++ developer should be able to write code to traverse a binary tree in 60 minutes, no problems.When you ask questions like "how do you traverse a binary tree" are you asking them for every precise step in C++ or are you just looking to see that they know the gist of it all?
I'm not sure I have exact numbers, and if I did, I'm not sure I'd be comfortable sharing them. If I receive 100 resumes, I might screen five to seven of the applicants. Of those seven, one or two might pass to an interview loop. Of the interview loops, maybe one of 50 gets hired. 7/100 * (2/7) * (1/50) = 14/35000 which is 0.04%, unless I'm having a bad math day. That number might be artifically low because we receive lots of unsolicited resumes from people who don't meet the minimum qualilfications we list for employment or aren't applying for positions we actually hire.Exactly how many potential hires do not end up qualify? The pickings are definitely slim...
What do you think they might be? If someone really knows how to do a rudimentary task, I don't think pressure is a factor in completing that task. Be mindful that we're not flunking people because they forgot a semicolon -- we're flunking people because they simply can't come up with a working algorithm that they can translate to some kind of code that mostly looks correct.Specifically regarding your linked-list code example in an interview, I think that's a very poor way to test candidates to see if they know how to code. There are a ton of factors that determine a candidate's success in this test, and the smallest is probably whether or not they know how to do it in the first place.
We end up interviewing such people all the time. I would've hoped that experienced developers wouldn't have such problems, but they do.Do you really think that an experienced developer who sounds reasonably intelligent when they speak to you cannot reverse a linked list?
Yes, I'm sure it's not an intimidating atmosphere. Interviews are tough, and everyone knows that. We do everything we can to keep the candidate calm. Being able to think clearly in tough situations is important, and people who are successful can do it.Are you sure it's not an intimidating atmosphere that temporarily blocks the ability to think clearly? I failed a polygraph for the same reason once.
We've considered doing things like this, but it's something we eschew for a few reasons:I think a better test is to give them a larger task, a couple days to complete it, and see how they do. They can work at their own pace in their own setting and have no reason not to complete the task you've given in the time allotted. I've done this with applicants in the past, and it works well.
If you don't ask a programmer to program, how do you know they can program? Why would you hire them without knowing if they can, and how they would, develop on their advertised skill? If you don't know if they a rank beginner or a world master, how do you decide how to structure their compensation?I'm sure in your position I would be content with what has worked in the past, but for me right now I wouldn't even think of having someone write actual code in an interview.
What do you think they might be?
Writing code to reverse a linked list is trivial; even if done wrong, it's only a dozen lines of code. I assert that candidates who can't complete something like this in 60 minutes aren't developers who know C or C++. There's nothing creative about this, and they've got lots longer than 15 minutes to solve it.
If you are grading to absolute completion, then yes it will be difficult. If you are examining overall architecture of the solution and leaving the minutiae as a secondary consideration, and giving the applicant appropriate prompting as to where they should spend their time, then I don't see why time should be an issue. A lot of this depends on the position though. This would be much more difficult to pull off with a theoretical position than a sw architectural position.Above all, though, it seems like most professionals wouldn't have the kind of time necessary to devote to such a test.
I don't think you're going to determine this from coding questions. When it comes to this level, you're either going to have a pre-qualification test or you're going to be asking questions verbally and getting verbal responses.If you don't ask a programmer to program, how do you know they can program? Why would you hire them without knowing if they can, and how they would, develop on their advertised skill? If you don't know if they a rank beginner or a world master, how do you decide how to structure their compensation?
polygraphs are bullshit and meaningless.
while mikeblas might sound "elitist", he is not being overly critical of many of the applicants he sees, and is correct: most "programmers" can't program. It's actually not exclusive to programmers. Most EE graduates can't analyze many simple op-amp circuits, many ME graduates can't do common force balances, etc.
It's complicated, for a variety of reasons:
- People that are incompetent are unaware that they are incompetent
- Many companies have people completely unfamiliar with the subject matter do the hiring
- Schools program the desire to learn out of students
- People go to universities for a degree instead of an education
Mark Twain said:I have never let my schooling interfere with my education.
#1 is absolutely true.
#2 I don't buy... software companies that have HR reps do engineer hiring probably don't last very long.
#3 I also don't buy... enthusiastic programmers are enthusiastic regardless of their education. School teaches you common solutions and proper practices and design patterns. If that ruins your enthusiasm then this isn't the field for you. Software companies live and die on the sustainability of their code base.
#4 totally agree
Then I'm not sure what more we can do. What are your suggestions?Assuring people that they're in a friendly environment is probably not going to get them past this.
In a way, we don't. Some candidates reverse the list in 5 minutes. Some stumble through it in half an hour. Others burn 45 or 60 minutes and, at the end, don't have working code, can't see the problem, tied their pointers in knots, and can't recover. It's the last band of candidates that trouble me -- these are people who claim to be professional C or C++ programmers.In this instance, I wouldn't place much of an emphasis on time to completion, though.
A coding question is a verbal question. We ask lots of other questions which gauge our offer. Point is, if we don't ask even a coding question, we've got no real idea of the skill for which we'd be paying the candidate.I don't think you're going to determine this from coding questions. When it comes to this level, you're either going to have a pre-qualification test or you're going to be asking questions verbally and getting verbal responses.
I'm sorry that nameless had a problem with a polygraph, but I struggle to relate it to this situation. An interview is stressful, but it's not as stressful as many situations which might arise at work day-to-day. If the servers go down, do you want someone who panicked in the interview and is panicking now, or do you want someone who's grabbing a stack of hard drives and a tool kit and driving to the data center?polygraphs are bullshit and meaningless.
It's complicated, for a variety of reasons:
- People that are incompetent are unaware that they are incompetent
- Many companies have people completely unfamiliar with the subject matter do the hiring
- Schools program the desire to learn out of students
- People go to universities for a degree instead of an education
Then I'm not sure what more we can do. What are your suggestions?
I'm sorry that nameless had a problem with a polygraph, but I struggle to relate it to this situation. An interview is stressful, but it's not as stressful as many situations which might arise at work day-to-day. If the servers go down, do you want someone who panicked in the interview and is panicking now, or do you want someone who's grabbing a stack of hard drives and a tool kit and driving to the data center?
In a way, we don't. Some candidates reverse the list in 5 minutes. Some stumble through it in half an hour. Others burn 45 or 60 minutes and, at the end, don't have working code, can't see the problem, tied their pointers in knots, and can't recover. It's the last band of candidates that trouble me -- these are people who claim to be professional C or C++ programmers.
Some people are incompetent and aware of it; there's conscious incompetence and unconscious incompetence. Unconscious incompetence is bad; in that mode, a person doesn't improve (they don't know they need to, and don't know how) and is resistant to feedback. Feedback is the only thing -- next to a sudden personal realization -- that will switch them from Unconscious incompetence to conscious incompetence. Conscious incompetence is actionable.
I'm much more interested on your take on the other things I said in my first (massively edited) post. The things that I mentioned before asking you about your interview environment are experiences that I've had and observations I've made. I'm interested to hear your interpretation of these things.
Why is it that it's so hard to hire good engineers? Is the problem that students are poorly prepared by the school system, or is it something else?
you may think polygraphs are meaningless and bullshit but you cant get a good job in the private sector without passing one (boeing, lockheed, raytheon etc)
The phases of competence aren't unique to handgun training. They're rooted in education theory -- I think they were developed by a corporate training company back in the 1970's. They're applicable in learning almost any new skill, and in continuing education. I've encountered them in sports where I have taken coaching or lessons, and I think I first found out about them in some management training retreat years ago.Heh, sounds like you're channeling some of Jeff Cooper's handgun training philosophy.
I couldn't disagree more. There's no trick to the question at all -- I don't think there's a trick to any of the others in my posts, either. The only goal is demonstrating competence, and perhaps doing so in a question that's difficult to take someone a little time to implement so we can talk over what they're thinking and how they approach the problem.The only thing about this particular question (and a few of the others I saw on the thread you linked), is that it's really a "know the trick and implement it" question.
Yep. But at that point, we might not be into thought process. we'd agree to the algorithm -- like the one you verbally described here -- and ask the candidate to implement it. If they're not able to implement it, then they're not a programmer.Of course, implementing it bug-free on a whiteboard or piece of paper is the next step, but I don't know how much thought process you're going to get from me for that.
I agree, as it offers more room for exploration. We usually ask the linked list question (or one like it) during a screen -- when we just want to establish that the candidate is worth an interview loop in the first place. There are lots of interesting questions to ask.In my mind, it seems to be a better question than the reversing a linked list one.
I don't have (and wouldn't share, anyway) rates for specific reasoning. We ask harder programming questions, and that helps us scope how good of a programmer people are. We ask questions about deciding what to work on -- writing code is the easy part; deciding what code to write is harder. We ask questions that help show idea generation, and that's more about raw intelligence and problem solving. We ask questions about product focus -- like comparing competing products, and that goes a bit towards customer interest, too. There's also something for personality fit. I guess we'll lose candidates very (very!) occasionally to visa issues or compensation problems, but those are the rarest of issues.However, I do wonder just how difficult the interviews get once you get past the basics. When you say you're having trouble finding "good" engineers, at what point does the transition from the obviously incompetent to the "can program, but not well enough to work here" occur? What other traits make the distinction between the 50 "made it to interviews" candidates and the 1 hire?
There are plenty of good jobs in the private sector that don't require a polygraph.you may think polygraphs are meaningless and bullshit but you cant get a good job in the private sector without passing one (boeing, lockheed, raytheon etc)
Yes.
void ReverseList( Node* node, Node* prev )
{
if( node )
{
ReverseList( node->Next, node );
node->Next = prev;
}
}
int main ( void )
{
List list;
for( int i = 0; i < 10; ++i )
list.push_back( new Node(i) );
list.print();
ReverseList( list.Head, NULL );
std::swap(list.Head, list.Tail);
list.print();
}
Output:
C:\>g++ test.cpp -enable-auto-import
C:\>a
0 1 2 3 4 5 6 7 8 9
9 8 7 6 5 4 3 2 1 0
Indeed, they appear to have been made by Gordon Training International in the 1970s. For some reason I attributed them to Cooper, as his Modern Technique came out in the 50s, and the current iteration of that largely emphasizes that kind of competency. Ah well, point still applies, at some point you cross that line in different areas of your skillset, though regression is possible when out of practice.The phases of competence aren't unique to handgun training. They're rooted in education theory -- I think they were developed by a corporate training company back in the 1970's. They're applicable in learning almost any new skill, and in continuing education. I've encountered them in sports where I have taken coaching or lessons, and I think I first found out about them in some management training retreat years ago.
The linked list loop (rabbit and hare iterators) is definitely an "aha" problem. Sure, you could theoretically solve it other complicated ways involving hash tables and such, but two iterators is the only one that I think (slash have heard) is commonly considered the "right" solution. Am I missing something (NO HIRE!)?I couldn't disagree more. There's no trick to the question at all -- I don't think there's a trick to any of the others in my posts, either. The only goal is demonstrating competence, and perhaps doing so in a question that's difficult to take someone a little time to implement so we can talk over what they're thinking and how they approach the problem.
Fair enough. Other ways I could think of would be to create a second copy in memory then reassign head, still roughly the same algorithm, but with the bonus of being thread safe and the downside of being memory inefficient. Hm, there's also recursive, but that is essentially the same as iterative (if using tail recursion). Can't really think of any others, do you have one?You can reverse a linked list in three or four different ways, and none are tricky. They're just ways to manipulate the list.
Yep. But at that point, we might not be into thought process. we'd agree to the algorithm -- like the one you verbally described here -- and ask the candidate to implement it. If they're not able to implement it, then they're not a programmer.
I enjoyed thinking about this one before checking if my solution was close to the optimal one (though it could probably be tuned for a larger set, I'd have to test it). There were other things I thought of, but they all came out roughly the same - divide and conquer. Still, I do need to find time to play with some of the others you've posted, they are a lot of fun to mentally work out on the drive home and then try to implement.At that point -- programmer or not? -- the difference is huge. Programmers understand the reality of implementation. Some of the other questions drive squarely at that. The one that asks for the median of a list of 500 trillion integers is one: candidates fail because they don't know what a median is. We explain it, then they go on to say that they'll just sort the list and pick the middle.
But if you have 500 trillion integers, how much memory and time do you need to perform the sort? Saying "just load the list and sort it" is easy -- writing working code to actually do that takes insight and talent.
Curl up in a ball and cry?I agree, as it offers more room for exploration. We usually ask the linked list question (or one like it) during a screen -- when we just want to establish that the candidate is worth an interview loop in the first place. There are lots of interesting questions to ask.
But there's surface area on the linked list question, too. Of the three or four working solutions, there's always room for more questions about performance, stability, maintainability, debugging, testing, threading performance, and so on.
It's a trivial question -- anyone who's taken C++ and Data Structures (and passed, LOL) should be able to do it. But you can ask candidates with advanced skills more questions about it. If the candidate claims the be a multi-threaded scale-out genius, how would he approach the problem on a computer with 400 processor cores and a list size of a billion?
Understandable. How does job placement work at Valve, if you're allowed to disclose? There are "job openings" posted on the website, but they seem much more generic and broad than the ones here at MS.I don't have (and wouldn't share, anyway) rates for specific reasoning. We ask harder programming questions, and that helps us scope how good of a programmer people are. We ask questions about deciding what to work on -- writing code is the easy part; deciding what code to write is harder. We ask questions that help show idea generation, and that's more about raw intelligence and problem solving. We ask questions about product focus -- like comparing competing products, and that goes a bit towards customer interest, too. There's also something for personality fit. I guess we'll lose candidates very (very!) occasionally to visa issues or compensation problems, but those are the rarest of issues.
Try that algorithm with a list that is 1000 items long.Got bored and thought about the reverse list problem everyone was fussin over.
Code:void ReverseList( Node* node, Node* prev ) { if( node ) { ReverseList( node->Next, node ); node->Next = prev; } } int main ( void ) { List list; for( int i = 0; i < 10; ++i ) list.push_back( new Node(i) ); list.print(); ReverseList( list.Head, NULL ); std::swap(list.Head, list.Tail); list.print(); } Output: C:\>g++ test.cpp -enable-auto-import C:\>a 0 1 2 3 4 5 6 7 8 9 9 8 7 6 5 4 3 2 1 0
You can obviously see that I'm awesome and should be hired right away...
You might try problems from this post, or think about some of the problems identified in this list. The first list has a few other interesting problems in the thread where it lives. Note, though, that we don't hire entry-level employees -- we don't consider CS grads right out of college, normally, unless they have exemplary work that has received wide acclaim.
We're asking for working C or C++ code. We're not sticklers about syntax; we don't chase people out of the room for a missing semicolon. Someone who's an experienced C or C++ developer should be able to write code to traverse a binary tree in 60 minutes, no problems.
Try that algorithm with a list that is 1000 items long.
void ReverseList( Node*& head, Node*& tail )
{
Node* list = head;
Node* prev = NULL;
while( list )
{
Node* next = list->Next;
list->Next = prev;
prev = list;
list = next;
}
std::swap( head, tail );
}
int main ( void )
{
List list;
for( int i = 0; i < 1000; ++i )
list.push_back( new Node(i) );
list.print(100);
ReverseList( list.Head, list.Tail );
list.print(100);
}
C:\>g++ test.cpp -enable-auto-import
C:\>a
0 100 200 300 400 500 600 700 800 900
999 899 799 699 599 499 399 299 199 99