Search⌘ K

Errors

Explore the two main types of programming errors in C: syntax errors caused by breaking language rules, and logical errors where code runs but behaves unexpectedly. Understand how to recognize these errors and apply debugging techniques to fix bugs, enhancing your ability to write correct and efficient C programs.

Types of errors

Two types of errors occur while creating programs:

  1. Syntax errors (grammatical)
  2. Logical errors (semantic)
svg viewer

Syntax errors

The syntax error occurs when we don’t follow the rules of the programming language. The syntax errors are:

  • Reported by the compiler
  • Easy to deal with
...