Unit 5 Quiz
Which of the following is not true about top-down coding and testing?
You should always start by coding and testing the most difficult functions.
When you trace the execution of a program, you insert print() functions at key points in the program. It makes sense for these functions to do all but one of the following. Which one is it?
display the values of the global constants used by the function
To test the functions of a module from the IDLE shell, you
import the module and then call any function from the IDLE shell
Which of the following is not a common type of syntax error?
invalid variable names
The stack is available when an exception occurs. It displays a list of
just the functions that were called prior to the exception
When you plan the test runs for a program, you should do all but one of the following. Which one is it?
list the expected exceptions for each test run
When you use the IDLE debugger, you start by setting a breakpoint
on a statement before the statement you think is causing the bug
Which type of error throws an exception that stops execution of the program?
runtime
Which type of error prevents a program from compiling and running?
syntax
When the IDLE debugger reaches a breakpoint, you can do all but one of the following. Which one is it?
view the values of all the variables that you've stepped through