Блог пользователя kowalsk1

Автор kowalsk1, история, 6 лет назад, По-английски

I remapped the keybindings in Sublime Text 3 so that ctrl+v pastes the text and also indents it correctly, but i've tested it with codeforces and my code continues the same as before (when i didn't use paste and indent) : with a huge tab size. Although it´s not a huge problem, i'd like to see it fixed because it´s bugging me a little bit. So, if someone has experienced something similar before or has a clue of what might be causing this problem, please share it in the comments.

Thanks in advance.

  • Проголосовать: нравится
  • 0
  • Проголосовать: не нравится

»
6 лет назад, # |
  Проголосовать: нравится +1 Проголосовать: не нравится

Tabs can look different, depending on which Editor, IDE, Renderer, ... you are using. Usually you can change the size of the tab character in every environment you have. That's one of the main advantage of tabs. Some prefer 2 spaces indentation, some prefer 4 spaces, and some prefer even 8 spaces (like Codeforces). With the tab character every developer of a team can be happy.

If you want that your code to look everywhere the same, then just use spaces instead of tabs (like every other intelligent developer).

  • »
    »
    6 лет назад, # ^ |
      Проголосовать: нравится +1 Проголосовать: не нравится

    Pro tip: setup your editor so that it inserts 4 spaces when you press the tab key.