Notes:

The different types of errors:

  1. Logic Errors:
    • An algorithm mistake, causing different behavior in the program
  2. Syntax Errors:
    • Spelling errors and other typos such as forgetting a semicolon at the end of a line, forgetting indentation, quotes, braces, etc.
  3. Run-Time Errors:
    • This is when the code will work for a bit and then crash because of a bug in one of the lines of code. This can occur due to user input errors.
  4. Overflow Errors:
    • This happens from values that may be too large for the program to process or show.

Correcting Errors:

Syntax errors can be fixed by running through each line of code, and making sure that you have all the proper elements: quotes where necessary, semicolons at the end of the lines, and proper spelling of functions and variables that are being called.

Debuggers are also very useful tools which allow for the programmer to pause or play the program as the program runs to see where exactly the error is occurring.

Testing Programs:

It is very important to test the programs! Errors are a part of the programming process and it’s important to continuously test so that the errors don’t pile up at the end.

Quiz Results: