6 ms·
It's a great point we hear often, so I incorporated it into our last round of hiring. Some still couldn't do it with an IDE, their language of choice and access
by varjag 7y ago
It's a great point we hear often, so I incorporated it into our last round of hiring. Some still couldn't do it with an IDE, their language of choice and access to Google.
(sorting an array, with any algorithm you want)
- scarface74 7y agoWould using a built in library be acceptable? Actually in C knowing how to use qsort() does require having a little knowledge of how function pointers work. If they did, I would ask them what could be some drawbacks of using the built in qsort function (function call overhead). On the other hand, would you accept a bubble sort as a solution? Or the most degenerate case- a bogosort ;) ?
- varjag 7y agoBubble sort, bogosort, sleepsort, anything that solves the assignment (gets an array sorted) of course. And no, a library call would not count towards implementation, but it's not too much to ask from candidates with masters degrees.
- blub 7y agoI must have written a couple dozen sorts, but only in high-school or when preparing for interviews. It's the one thing that is very well supported in most programming languages. C++ has stable/unstable sorts, partial sorts, whatever you want. Accepting things like bubble sort also makes the exercise doubly pointless.
- scarface74 7y agoI partially agree, but a bubble sort is slightly harder than FizzBuzz (?) and even if you give them the algorithm, it might be a little more fair since knowing how to do a nested for loop is less esoteric than the mod operator. Now if someone did a BogoSort, I would hire them just for their ingenuity and sense of humor.
- james_s_tayler 7y ago10/10 I would go for randomize the array and check if it's sorted. Repeat if it's not. I like the people I work with to have a good sense of humor.
- varjag 7y agoSince people still fail it, even with all might of Google at their command, even with bubblesort allowed, it's anything but pointless. And if you are unable to sort an array it's a strong signal that command in all other areas of CS is lacking. Does C++ has a standard library for RSTP? Do you think a person who can't sort an array after 5 years of school would be able to fix a bug in a switch' spanning tree implementation?
- scarface74 7y agoIt depends on the position. If I’m looking for a developer for yet another software as a service CRUD app, I may not need anyone that understands “CS fundamentals”. Heck it’s been 20+ years since I graduated from college with my CS degree and over a decade since I’ve had to do any low level programming. Does C++ has a standard library for RSTP? Maybe not, but I know that there are very few new problems under the sun that most people face and someone has solved the problem before. I also know how to use Google. https://stackoverflow.com/questions/1460010/best-c-rtp-rtsp-library https://stackoverflow.com/questions/1460010/best-c-rtp-rtsp-...
- varjag 7y agoYou mixed up RSTP with RTSP, I would revisit my Googling skills if I were you.. making a beautiful case though for this kind of interview process. (before you go on googling again, the algorithm operates over the switch port forwarding fabric, you can't really use a library)
- scarface74 7y agoSo are you really saying that you could not look at an open source implementation and reimplement? https://github.com/shemminger/RSTP https://github.com/shemminger/RSTP
- varjag 7y agoYes, I am saying exactly that. This is a userspace implementation not making use of switch hardware fabric. You can probably hack hardware forwarding into it (haven't looked into this, our implementation predates it by 2 years). Or you can read an RSTP spec and implement it. None of it is secret, like none of CS in general is. Both approaches however would be beyond the skills of a programmer who can't sort an array. And really it's not a high bar, I don't understand this obsession with anti-intellecualism. Everyone likes plumbing analogies, well I wouldn't trust a plumber who doesn't know that water generally tends to flow downwards - it's this level of CS knowledge we are talking about here.