Exam 3 Study Vocab Flashcards

(87 cards)

1
Q

debugging

A

The process of finding and removing any of the three kinds of programming errors.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

exception

A

An error that occurs at runtime.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

interpret

A

To execute a program in a high-level language by translating it one line at a time.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

parse

A

To examine a program and analyze the syntactic structure.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

print statement

A

An instruction that causes the Python interpreter to display a value on the screen.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Python Shell

A

An interactive user interface to the Python interpreter. The user of a Python shell types commands at the prompt (»>), and presses the return key to send these commands immediately to the interpreter for processing.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

runtime error

A

An error that does not occur until the program has started to execute but that prevents the program from continuing.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

script

A

A program stored in a file (usually one that will be interpreted).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

syntax error

A

An error in a program that makes it impossible to parse — and therefore impossible to interpret.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

data type

A

A set of values. The type of a value determines how it can be used in expressions. So far, the types you have seen are integers (type int), floating-point numbers (type float), and strings (type str).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

expression

A

A combination of variables, operators, and values that represents a single result value.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

float

A

Python data type which stores floating-point numbers. Floating-point numbers are stored internally in two parts: a base and an exponent. When printed in the standard format, they look like decimal numbers. Beware of rounding errors when you use floats, and remember that they are only approximate values.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

int

A

A Python data type that holds positive and negative whole numbers.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

statement

A

An instruction that the Python interpreter can execute. Examples of statements include the assignment statement and the print statement.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

str

A

A Python data type that holds a string of characters.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

value

A

A number or string (or other things to be named later) that can be stored in a variable or computed in an expression.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

variable

A

A name that refers to a value.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

for loop

A

A statement in Python for convenient repetition of statements in the body of the loop.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

loop body*

A

Any number of statements nested inside a loop. The nesting is indicated by the fact that the statements are indented under the for loop statement.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

loop variable

A

A variable used as part of a for loop. It is assigned a different value on each iteration of the loop.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

instance

A
An object of a certain type, or class. tess and alex are different instances of the class Turtle. 
module
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

module

A

A file containing Python definitions and statements intended for use in other Python programs. The contents of a module are made available to the other program by using the import statement.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

object

A

A “thing” to which a variable can refer. This could be a screen window, or one of the turtles you have created.
function

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

function

A

A named sequence of statements that performs some useful operation. Functions may or may not take parameters and may or may not produce a result.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
header
The first part of a compound statement. Headers begin with a keyword and end with a colon (:) import statement
26
import statement
A statement which permits functions and variables defined in a Python script to be brought into the environment of another script or a running Python shell.
27
local variable
A statement which permits functions and variables defined in a Python script to be brought into the environment of another script or a running Python shell
28
parameter
A name used inside a function to refer to the value passed as an argument.
29
boolean expression
An expression that is either true or false.
30
boolean function
A function that returns a boolean value
31
None
A special Python value returned by functions that have no return statement, or a return statement without an argument. None is the only value of the type, NoneType.
32
return value
The value provided as the result of a function call.
33
counter
A variable used to count something, usually initialized to zero and incremented in the body of a loop.
34
cursor
An invisible marker that keeps track of where the next character will be printed.
35
decrement
decrease by 1
36
increment
increase by 1
37
flow of execution
The order in which statements are executed during a program run
38
infinite loop
A loop in which the terminating condition is never satisfied
39
iteration
Repeated execution of a set of programming statements.
40
nested loop
A loop inside the body of another loop
41
new line
A special character that causes the cursor to move to the beginning of the next line.
42
index
A variable or value used to select a member of an ordered set, such as a character from a string.
43
slice
A part of a string (substring) specified by a range of indices. More generally, a subsequence of any sequence type in Python can be created using the slice operator (sequence[start:stop
44
aliases
Multiple variables that contain references to the same object.
45
clone
To create a new object that has the same value as an existing object. Copying a reference to an object creates an alias but doesn’t clone the object.
46
mutable type
A data type in which the elements can be modified. All mutable types are compound types. Lists are mutable data
47
immutable`
A compound data type whose elements cannot be assigned new values
48
sequence
Any of the data types that consist of an ordered set of elements, with each element identified by an index
49
recursion
The process of calling a function that is already executing.
50
recursive call
The statement that calls an already executing function. Recursion can also be indirect — function f can call g which calls h, and h could make a call back to f.
51
dictionary
A collection of key-value pairs that maps from keys to values. The keys can be any immutable type, and the values can be any type.
52
key
A data item that is mapped to a value in a dictionary. Keys are used to look up values in a dictionary.
53
key-value pair
One of the pairs of items in a dictionary. Values are looked up in a dictionary by key.
54
mapping type
A mapping type is a data type comprised of a collection of keys and associated values. Python’s only built-in mapping type is the dictionary. Dictionaries implement the associative array abstract data type.
55
directory
A named collection of files, also called a folder. Directories can contain files and other directories, which are refered to as subdirectories of the directory that contains them
56
file
A named entity, usually stored on a hard drive, floppy disk, or CD-ROM, that contains a stream of characters.
57
delimeter
sequence of one or more characters used to specify the boundary between separate parts of text.
58
mode
A distinct method of operation within a computer program. Files in Python can be openned in one of three modes: read ('r'), write ('w'), and append ('a').
59
handle
An object in our program that is connected to an underlying resource (e.g. a file). The file handle lets our program manipulate / read/ write / close the actual file that is on our disk.
60
object oriented programming
A powerful style of programming in which data and the operations that manipulate it are organized into classes and methods.
61
class
User defined compound data type. A class, can also be thought of as a template for objects that are an instance of it
62
instance/object
An object whose type is of some class. Instance and object are used interchangeably.
63
method
``` A function that is defined inside a class definition and is invoked on instances of that class. attribute ```
64
attribute
One of the named data items that makes up an instance.
65
initializer method
A special method in Python (called __init__) that is invoked automatically to set a newly created object’s attributes to their initial (factory-default) state.
66
instantiate
To create an instance of a class, and to run its initializer.
67
GUI
A graphical user interface (GUI) is a human-computer interface that uses windows, icons and menus and which can be manipulated by a mouse (and often to a limited extent by a keyboard as well).
68
widget
an element of a (GUI) that displays an information arrangement changeable by the user, such as a window or a text box.
69
database
an organized collection of data for one or more purposes
70
web scraping
a computer software technique of extracting information from websites
71
canvas
a highly versatile widget which can be used to draw graphs and plots, create graphics editors, and implement various kinds of custom widgets.
72
radiobutton
used to implement one-of-many selections. Radiobuttons can contain text or images, and you can associate a Python function or method with each button. When the button is pressed, Tkinter automatically calls that function or method. button
73
text entry
allows you to display and edit text with various styles and attributes. The widget also supports embedded images and windows.
74
label
used to display a text or image on the screen. The label can only display text in a single font, but the text may span more than one line. In addition, one of the characters can be underlined, for example to mark a keyboard shortcut.
75
regular expresion
use the backslash character ('\') to indicate special forms or to allow special characters to be used without invoking their special meaning.
76
algorithm
A step-by-step process for solving a category of problems. | bug
77
bug
An error in a program
78
executable
Another name for object code that is ready to be executed.
79
formal language
Any one of the languages that people have designed for specific purposes, such as representing mathematical ideas or computer programs; all programming languages are formal languages. high-level language
80
compound data type
A data type in which the values are made up of components, or elements, that are themselves values. default value
81
dot operator
The dot operator ( .) permits access to attributes and functions of a module (or attributes and methods of a class or instance – as we have seen elsewhere).
82
namespace
A syntactic container providing a context for names so that the same name can reside in different namespaces without ambiguity. In Python, modules, classes, functions and methods all form namespaces.
83
naming collision
A situation in which two or more names in a given namespace cannot be unambiguously resolved. Using import string instead of from string import * prevents naming collisions.
84
file system
A method for naming, accessing, and organizing files and the data they contain. fully qualified name
85
path
a sequence of directory names that specifies the exact location of a file
86
modifier
A function or method that changes one or more of the objects it receives as parameters. Most modifiers are void.
87
whitespace
Any of the characters that move the cursor without printing visible characters. The constant string.whitespace contains all the white-space characters.