News for hackers. Stuff that matters.
Re:Why I Don’t Talk to Google Recruiters by Jach on Tuesday February 21, 2017 @03:06PM (#13699342)
I'd rather hire someone who can actually get the job done in a timely manner. We can optimize it later, especially after profiling to know exactly what we need to optimize, and especially if there are security implications that mean we can't ruthlessly optimize everything. People who optimize too soon end up with solutions that are hard to change later, or solutions that don't even do the job they're supposed to. It's all too easy to get a half-working version that's super fast by focusing on the speed part more than the working part. https://alibgoogle.wordpress.com/2011/02/18/scheme-vs-c/ is worth a read. "Real efficiency comes from elegant solutions, not optimized programs. Optimization is always just a few correctness-preserving transformations away."

There are some "free" optimizations I'd expect a lot of seasoned programmers to be familiar with, like as you mention the string concatenation issue, but those are easy to catch during code review. Similarly for certain optimizations that are even 'freer' in the sense that modern compilers will take the easier-to-read (if naively slower) version and produce the fast version, I expect to not have to tell people during code review that the 'slower' version isn't slow because the compiler does the right thing.

Re:Why I Don’t Talk to Google Recruiters by hashseed on Tuesday February 21, 2017 @04:06PM (#13699974)
Often enough, implementing the optimal solution is not really more time-consuming than the brute force solution. Often it's not about micro-optimizations, but a difference between O(n^3) and O(n*logn).
Re:Why I Don’t Talk to Google Recruiters by Jach on Tuesday February 21, 2017 @04:22PM (#13700143)
I guess I think of programming in a big company as a team exercise. And thus the hiring pipeline can take advantage of specialization and good-enough economics, as well as teaching people more on-the-job. It's a large burden if you demand everyone on the team know the same first principles (of course there may be disagreement on what those are). Even if personally I want to know as much as I can and get along with others who do too, I'm not really going to hold it against a team member if they produce a poor-complexity algorithm that in review I (or someone else, I think it is good to have at least one person on the team who has algorithm knowledge) notice and can suggest an alternative that's easy to use instead. If they do it again (for the exact same thing) I might raise an eyebrow and remind them of the repeat mistake. If they do it a third time I might write them off as incapable of learning new things. But this pattern applies to other aspects of software too. e.g. Getting people to write testable code can itself be a hassle if they haven't been exposed to that before. Or something as dead simple as getting people to use the rest of the team's coding style guidelines, I've seen interns who still had problems with that near the end of the summer internship, I wouldn't be very happy if it was a senior colleague...
Re:Why I Don’t Talk to Google Recruiters by msangi on Tuesday February 21, 2017 @04:34PM (#13700249)
The problem is when the goal is to get something out of the door as soon as possible. In such cases developers tend to settle for the first thing that comes to their mind, which is rarely an elegant solution.

These require experience and time spent carefully designing the system. A profiler shows you what is slow in your current implementation, not how to convert it to a more elegant one.