Live data from Hacker News

Developers who use spaces make more money than those who use tabs

stackoverflow.blog

281–290 of 690 posts

Re: Developers who use spaces make more money than those who use tabs

#281
post #18

Of course professionals get paid more, but I'm surprised there are so many tab users out there! Time to add a new interview question.

I believe the correct answer to that interview question would be "Follow the code style as established by the company, or keep it consistent within existing projects."

Agreed. People who follow the style guide probably earn more than either spaces or tabs.

Re: Developers who use spaces make more money than those who use tabs

#283
post #218

Earlier quoted context omitted.

I have never seen this work correctly in practice, where a code base with tabs looks "OK" when opened on an editor with a different tab width. E.g. some coding styles will have subsequent lines line up (like multiline method params), and everything looks horrible with a different tab width. If anyone can post a sizable production code base that uses tabs that DOESN'T look like shit with a different tab width, I'm cer…

FreeBSD, Linux ... every UNIX kernel codebase ?

This feels like a partial proxy question for Unix versus non-Unix development. Unix developers are, in my experience, consistently more interested in configuring their IDEs, which underlies many of the arguments for tabs over spaces.

Re: Developers who use spaces make more money than those who use tabs

#285
post #207

Earlier quoted context omitted.

> when another developer looks at the code, their IDE will render the tabs as whatever its set up for, 2 spaces, 4 spaces, etc. This is an argument I hear often from tab proponents. What it misses out is the downside: my IDE has a certain arrangement on my screen, and I'll either have to invoke horizontal scrolling or I'll have a bunch of wasted space if you are using different size tabs from me. This is far from fle…

> if you are using different size tabs from me. But the point of tabs is that you tell your editor how many spaces wide you want them to be, so unless I'm misunderstanding you, this is not an issue. As for lining things up, tabs are used for the indentation level of the current line, but if you need to further nudge things within that line then you'd of course use spaces (after the initial tab indent).

You misunderstand me. I can set my tab size different from yours, but doing that will change the horizontal window width required to view your code. This is the problem I'm describing.

Re: Developers who use spaces make more money than those who use tabs

#286
post #123

The reason I use tabs is pretty simple. It's faster to move around only using the keyboard. It's also faster if I'm changing code that requires reformatting. Finally, when another developer looks at the code, their IDE will render the tabs as whatever its set up for, 2 spaces, 4 spaces, etc. In other words, it adds flexibility. Brace yourself: I use two spaces after the end of sentences too. [1] I am quite the rebel.…

> Finally, when another developer looks at the code, their IDE will render the tabs as whatever its set up for, 2 spaces, 4 spaces, etc. In other words, it adds flexibility. This is exactly why I use tabs and the reason which appears to never get cited in the holy wars. People who use spaces want to line up their '=' signs, that's fine, but I don't believe it's my position to enforce the amount of whitespace another…

> People who use spaces want to line up their '=' signs

How does that prevent the use of tabs? You can use tabs to indent, and spaces for your = signs.

Re: Developers who use spaces make more money than those who use tabs

#288
In terms of potential explanatory covariates, I think preferred editor/IDE would be one of the most likely to explain the trend, since different editors will have different defaults. The survey has this information, so someone could test this. It would probably help to group the editors by their default setting. I think you might need a mixed model with editor as a random effect to include both default setting and preferred editor in the same model.

Re: Developers who use spaces make more money than those who use tabs

#289

Almost certainly a result of the spaces cabal and the (often unspoken of) prejudice against tab users. Don't think you make hiring decisions based on tabs vs spaces? Well you're part of the problem, then. I'm building an app to help you easily email your congressperson and ask them to create legislation requiring space/tab equality. This has to stop. Please consider donating to my Patreon.

> Don't think you make hiring decisions based on tabs vs spaces? I actually ask candidates "spaces or tabs?" in every single interview. I don't really care what the response is in regard to the holy war, and it doesn't mean anything on its own, but having SOME thought out response can be a GREAT indicator of how well versed someone is in general. e.g. I'm going to think way more highly of someone that says "tabs, bec…

My answer would be: why are you asking me? Shouldn't I be asking you? Do you have coding standards here? Or is it going to be my job to decide on the coding standards?

Re: Developers who use spaces make more money than those who use tabs

#290
post #276

Well, of course. Only companies with fuck-you money can afford the extra bytes spaces take up versus tabs, so it follows logically that they'd pay their developers more.

While your comment is obviously meant as a joke, it somehow rings true from my anecdotal experience. I'd also like to see an analysis of space-vs-tabs as it relates to operating systems. Again, from anecdotal experience, it seems spaces are more common for folks with *nix background who tend to work in product-oriented companies (i.e. where code is an asset) and tabs are more common with windows folks, who tend to wo…

This is...this is actually brilliant logic.
Post reply on HN