Answer the question
In order to leave comments, you need to log in
Why use two spaces instead of one tab?
What's the point of using 2 spaces instead of one tab, because tabs can be adjusted later, and spaces aren't much, since they affect the rest of the code (spaces throughout the document are its entire integral part, while tabs are used only for indents and nowhere else)?
Answer the question
In order to leave comments, you need to log in
Code written in tabs can be displayed differently depending on the editor settings. And spaces remain spaces and there is no such problem with them. Whitespace is the standard in most large companies and in the open source community.
Also, programmers who use spaces earn more on average . But this is because good companies have high standards for code quality.
Modern IDEs (like Webstorm) replace tabs with spaces by default.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question