How to understand where is the error? | Sololearn: Learn to code for FREE!


How to understand where is the error?

i = 15 for i in range(1,5): while(i<3): print("hi") i+ = 1 continue print(i) pass print(i)

7/24/2021 12:23:05 PM

Swapna Jha

2 Answers

New Answer


Debugging line by line and check the output....that's it


Swapna Jha Just see the error and understand it and solve it step by step. Error maybe come in different case in python like: 1 - Indentation problem 2 - syntax error 3 - logical error 4 - grammatical error. As I can see in your code there is Indentation problem and also incorrect use of += also doens't make sense to use of continue and pass here.