1/15
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced |
---|
No study sessions yet.
bug
An error in a program.
debug
finding and fixing problems and errors in a program
Syntax error
An error that results when an instruction does not follow the syntax rules or grammar of the programming language.
Logical error
An error in a program that produces unintended or undesired output, where the syntax is correct but some other human error has occurred.
Run-time error
A mistake in a program that happens only when the program is actually run, such as a program attempting to access memory that does not exist.
adding extra indentation is an example of
syntax error
spelling mistakes are an example of
syntax error
missing : or { } or ( ) is an example of
syntax error
The program is printing out the wrong name of the student, this is an example of
logical error
trying to print out the 6th element in an array of 5 elements is an example of
run-time error
The built-in Python debugger allows developers to pause program execution, inspect variables, and step through the code.
pdb
a popular Python IDE comes with a powerful debugger that provides features like stepping through the code, breakpoints, and variable inspection.
PyCharm Debugger
a popular IDE that includes a versatile debugger with support for remote debugging, multi-threaded debugging, and conditional breakpoints.
Visual Studio Code Debugger
Built-in logging module can be used to record the flow of the program and help identify issues
Logging
Tools like pylint and flake8 can catch potential issues in the code that might lead to errors.
Linter
Tools like cProfile and memory_profiler can help identify performance bottlenecks.
Profiling Tools