44
Python
7y

Apparently you make more money if you use spaces than if you use tabs

https://stackoverflow.blog/2017/06/...

Comments
  • 4
    Naaah, you don't.
    Guy is just compensating the fact he uses spaces by wearing fancy clothes.

    Me:
    *Runs like hell*
  • 2
    Kek, it's like you're paid for every character you type, then sure, using spaces over tabs increase the char count.
    No seriously, i still don't get how could anyone use space over tabs, does anyone have an answer?
  • 1
    Pretty much all big projects, frameworks and employers use spaces — so I use spaces (well, soft tabs).
  • 0
  • 0
    No you don't. If A means B then B does not necessarily means A
  • 0
    How about tab that represents 4 spaces? :o
  • 2
    Am I the only who doesn't get the whole tabs-vs-spaces thing? I press the tab key and have my IDE configured to insert 4 spaces so what's the big deal. No one in their right mind presses the space bar. Also a space is a space everywhere. When I open code which uses the tab symbol the width changes depending on the editor.
  • 3
    @Alfer I used tabs for half my life, and there is only one benefit: the file size is slightly smaller. Other than that, tabs are worse. Now I am using spaces for most of my projects. When I say spaces, I mean soft tabs: I press the tab key and it inserts 4 or 2 spaces, any sensible editor allows that, as well as autoindenting etc.

    The main problem is: how long is a tab? For you might be the width of 4 spaces. For others it's 2, and purists will say it's 8. Now, let's say that you want to align inline comments or variables. You are forced to use spaces as well because you can't insert half of a tab. But the amount it spaces you will use will depend on how wide is a tab for you (a width that you have to agree with your team on, or you will go crazy). With spaces that problem is gone, because a space is just width 1 always. Even more, try to make an ascii table with tabs (tabs+spaces) and now do it just with spaces. Aligning ANYTHING is always easier with spaces!
  • 0
    @codedoge exactly what you said. I couldn't agree more.
Add Comment