The function to get the length of a string.
What is len(str)?
This error prevents the program from starting.
What is a syntax error?
This loop will keep running as long as a condition is true, good for when you don't know how many times it will need to loop.
What is while(condition)?
The function used to open a file, and the function used to close a file.
What is open() and close()?
The three conditional statements.
The function to convert a type to a string.
What is str(var)?
This error crashes the program, but allows it to start. Often called an "exception".
What is a runtime error?
Keyword that exits the current loop immediately.
What is break?
Skip a line using this function.
What is next(file)?
The function to remove the whitespace from the beginning and end of a string.
What is .strip()?
The program starts and doesn't crash, but this error makes it so it doesn't quite work the way it should.
What is a semantic error?
Loop that executes a specific block of code a specified number of times.
What is for()?
Used to parse through a file.
What is a for loop?
Used in place of "magic numbers" and can be accessed by any function in the program.
What is a constant?
The function used to divide a string based on a given delimiter.
What is .split()?
This is all the information provided by a stack trace.
What is the error type, line of code that most recently crashed, and an error message?
This function used in loops doesn’t actually make a list, but creates this type of iterable object instead.
What is a range?
Use this line of code to open a file and automatically close it once its done being read.
What is
with open(filename) as file:
?
A range that includes the numbers from 0 to 10.
What is range(0, 11).
This character encoding standard represents letters and symbols as numbers.
What is ASCII?
Usually used in testing, raise an exception manually.
What is raise?
Keyword that stops the current iteration of the loop and skips to the next one.
What is continue?
Function in the csv module that is used to read a CSV file.
What is .reader(csv_file)?
In a try/except block, this clause runs no matter what, even if an error occurs.
What is finally?