|Type of error
|Why does this error occur?
|Example of how this error is indicated
|Syntax errors occur when you type something wrong; you could have missed part of a statement or misspelt it.
|Statements must be separated by newlines or semicolons
|Indentation errors occur when you make a mistake with the code structure.
|Expected indented block
|This happens when you put the wrong type of data in the wrong place in your code, such as trying to add a string to an integer
|Operertor "x" is not supported for type.
|A name error occurs when you try to use a variable or function that has not been defined yet.
|"a" is not defined
|This means that there is nothing wrong with the code regarding indentation and syntax, but the logic of the code or algorithm is incorrect
|This means that the program you are running never reaches the code indicated by the error
Python Editor: Troubleshooting errors Print
Modified on: Tue, 17 May, 2022 at 3:18 PM
Did you find it helpful?Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.