0

How can I avoid frequent Python indentation errors?

Indentation errors

11th Jun 2019, 12:59 PM
Gaurang Rai
Gaurang Rai - avatar
5 ответов
+ 12
good point Anna , ... and, it's alternately : )
11th Jun 2019, 1:23 PM
Cépagrave
Cépagrave - avatar
+ 10
Can you give us an example of indentation error you get ?
11th Jun 2019, 1:13 PM
Cépagrave
Cépagrave - avatar
+ 7
It's a word, Anna. 🙂 Don't mix tabs and spaces, stick to one width.
11th Jun 2019, 3:46 PM
HonFu
HonFu - avatar
+ 6
Use ide and add extension code snippets and stuff... Google it
11th Jun 2019, 1:16 PM
minirkk
minirkk - avatar
+ 4
Pick a fix amount of indentation (usually four spaces) and stick with it. In one of your codes, you use 2 and 5 spaces alternatingly (<= is that a word?). That's usually not a good idea
11th Jun 2019, 1:19 PM
Anna
Anna - avatar