Question: what is the difference between a syntax error and an execution error?
Answer: An execution error occurs when a program is asked to do something that it cannot, resulting in a 'crash'. The widely used example of a run time error is asking a program to divide by 0. syntax error occurs when there is some grammatical error ,like for eg.