Notepad++ indentation messes up

前端 未结 6 683
灰色年华
灰色年华 2020-11-30 01:55

I\'m coding in Python and I really like Notepad++. However, off late when I use tab to indent, it seems fine in Notepad++, but when I run the program I get an indentation er

6条回答
  •  臣服心动
    2020-11-30 02:23

    I am new to python and started using Notepad++. But I faced the same issue as you... Indentation problems. On my senior's advice, I switched to PyCharm community edition. I pasted the code from Notepad++ to PyCharm and it highlighted the block with indentation problems... The issue was that, some of the lines used spaces and some used tabs. This happened because the code on which I was working was taken from the internet.

    Checking for such inconsistencies would solve the problem. Or, there is a better alternative... Switch to PyCharm. It is exclusively built for python coding.. Hope this helps people like me searching for solutions for indentation issues in Notepad++

提交回复
热议问题