Hello!
Let us learn about errors in programming.
There are three types of errors :
[1] Syntax Error : Syntax errors are like spelling mistakes in your programming code when you don't follow the rules of programming language, such as, missing a semicolon, or a bracket.
The are caught by the compiler and are prevented from running until they are fixed.
[2] Logical Error : Logical errors are like using wrong word in a sentence, in your code it occurs if expected output is not produced.
These errors are caused by incorrect algorithm in the code and can be only fixed by the programmer.
[3] Runtime Error : Runtime errors occur when code encounter and expected situation during execution, such as, dividing by zero or exceeding time limit.
These errors are usually detected by operating system.