Name:     ID: 
 
Email: 

Python Final Exam

Completion
Complete each statement.
 

 1. 

A(n) ___________ is just a special function that we make in a class.
 

 

 2. 

Information required by a function or widget is called a(n) _________.
 

 

 3. 

The _______ widget provides a box for entering text.
 

 

 4. 

A(n) ____________ is a space in the computer’s memory where it can store a string or an integer.
 

 

 5. 

Working out why code doesn’t work as expected is called _________.
 

 

 6. 

Each value in a tuple is separated by a(n) ______.
 

 

 7. 

_________________ is writing instructions for computers.
 

 

 8. 

A(n) __________ is a file that gives you access to a number of functions that you do not have to write yourself.
 

 

 9. 

A(n) _______ is the equivalent of an index in a string, tuple, or list. It is defined by the programmer.
 

 

 10. 

A(n) ________ is a type of container that can store strings or integers that can be altered by other code.
 

 

 11. 

___________ are the values passed to a function.
 

 

 12. 

____________ are the values that you provide for a function to do its task.
 

 

 13. 

In Python the mathmatical operator % is called the __________.
 

 

 14. 

Number types that can have a decimal value are _______.
 

 

 15. 

_______ is Python’s version of elseif.
 

 

 16. 

If you are writing a tuple, use ________ brackets.
 

 

 17. 

A(n) ______ can store strings, integers and other data types and cannot be altered.
 

 

 18. 

The data container in which you create your own key is a(n) _________.
 

 

 19. 

To repeat in Python use a ________ loop.
 

 

 20. 


___________ appear in red in IDLE; these are aimed at people and begin with the ___ symbol. (enter each blank in order with a comma between)
 

 

 21. 

In object oriented programming, if you build ________ in the correct way, you can make libraries out of them.
 

 

 22. 

__________ are number data types that cannot have decimal values and must be whole numbers.
 

 

 23. 

A(n) ____________ is a piece of code that can be used again and again.
 

 

 24. 

To store the names of everyone in this class you should use a ______.
 

 

 25. 

Looking through any error messages that are output and checking your code is called ___________.
 

 

 26. 

A(n) __________ goes through the indented code as many times as required.
 

 

 27. 

A(n) ________ button applies a set function to a number.
 

 

 28. 

_________________ is a function that will print anything you put in the brackets.
 

 

 29. 

To get user input in Python use the _________ function.
 

 

 30. 

A(n) _________ is a collection of useful functions and data in one place.
 

 

 31. 

Variables that are outside of any function are available throughout the program and are called _______ variables.
 

 

 32. 

An unordered data type that stores values as key:value is a(n) _________.
 

 

 33. 

Variables that are declared inside a function and are not available outside their function are called ______ variables.
 

 

 34. 

Two equal signs together or a greater than symbol are both examples of ______________________.
 

 

 35. 

The number that references a value in a string, tuple, or list is a(n) ______.
 

 

 36. 

The properties or characteristics of an object are called _____________ or _______________.(enter each blank with a comma separating)
 

 

 37. 

The _______ function listens to the keyboard entry and waits for the return key to be pressed.
 

 

 38. 

To add comments to your code use the _____ symbol.
 

 

 39. 

A(n) ______________ is a screen that allows a user to interact with their computer through graphics.
 

 

 40. 

If you use two forward slashes instead of one in dividing, Python will produce a(n) __________ as an answer.
 

 

 41. 

The ______ is used to assign a value to a variable in coding.
 

 

 42. 

A variable that is created in a function is said to be a(n) ______________.
 

 

 43. 

In Python, create a variable by giving it a name and then assign data to it using the ________________.
 

 

 44. 

_______________ are common when typing code. If there are mistakes in your code you will get an error message.
 

 

 45. 

The ______ class is a tkinter factory that requires the arguments for a window, background color, height, and width.
 

 

 46. 

A variable that stores only the values True or False is called a(n) ________________.
 

 

 47. 

The process of converting one data type into another is called ________.
 

 

Short Answer
 

 48. 

Explain in your own words when to use classes.
 

 49. 

Explain what collision detection is and why you would use it in Python.
 

 50. 

Explain in your own words how to use coordinates in Python.
 



 
         Start Over