Exam 3 Study Vocab Flashcards

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
Q

header

A

The first part of a compound statement. Headers begin with a keyword and end with a colon (:)
import statement

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

import statement

A

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.

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

local variable

A

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

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

parameter

A

A name used inside a function to refer to the value passed as an argument.

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

boolean expression

A

An expression that is either true or false.

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

boolean function

A

A function that returns a boolean value

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

None

A

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.

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

return value

A

The value provided as the result of a function call.

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

counter

A

A variable used to count something, usually initialized to zero and incremented in the body of a loop.

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

cursor

A

An invisible marker that keeps track of where the next character will be printed.

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

decrement

A

decrease by 1

36
Q

increment

A

increase by 1

37
Q

flow of execution

A

The order in which statements are executed during a program run

38
Q

infinite loop

A

A loop in which the terminating condition is never satisfied

39
Q

iteration

A

Repeated execution of a set of programming statements.

40
Q

nested loop

A

A loop inside the body of another loop

41
Q

new line

A

A special character that causes the cursor to move to the beginning of the next line.

42
Q

index

A

A variable or value used to select a member of an ordered set, such as a character from a string.

43
Q

slice

A

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
Q

aliases

A

Multiple variables that contain references to the same object.

45
Q

clone

A

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
Q

mutable type

A

A data type in which the elements can be modified. All mutable types are compound types. Lists are mutable data

47
Q

immutable`

A

A compound data type whose elements cannot be assigned new values

48
Q

sequence

A

Any of the data types that consist of an ordered set of elements, with each element identified by an index

49
Q

recursion

A

The process of calling a function that is already executing.

50
Q

recursive call

A

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
Q

dictionary

A

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
Q

key

A

A data item that is mapped to a value in a dictionary. Keys are used to look up values in a dictionary.

53
Q

key-value pair

A

One of the pairs of items in a dictionary. Values are looked up in a dictionary by key.

54
Q

mapping type

A

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
Q

directory

A

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
Q

file

A

A named entity, usually stored on a hard drive, floppy disk, or CD-ROM, that contains a stream of characters.

57
Q

delimeter

A

sequence of one or more characters used to specify the boundary between separate parts of text.

58
Q

mode

A

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
Q

handle

A

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
Q

object oriented programming

A

A powerful style of programming in which data and the operations that manipulate it are organized into classes and methods.

61
Q

class

A

User defined compound data type. A class, can also be thought of as a template for objects that are an instance of it

62
Q

instance/object

A

An object whose type is of some class. Instance and object are used interchangeably.

63
Q

method

A
A function that is defined inside a class definition and is invoked on instances of that class. 
attribute
64
Q

attribute

A

One of the named data items that makes up an instance.

65
Q

initializer method

A

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
Q

instantiate

A

To create an instance of a class, and to run its initializer.

67
Q

GUI

A

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
Q

widget

A

an element of a (GUI) that displays an information arrangement changeable by the user, such as a window or a text box.

69
Q

database

A

an organized collection of data for one or more purposes

70
Q

web scraping

A

a computer software technique of extracting information from websites

71
Q

canvas

A

a highly versatile widget which can be used to draw graphs and plots, create graphics editors, and implement various kinds of custom widgets.

72
Q

radiobutton

A

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
Q

text entry

A

allows you to display and edit text with various styles and attributes. The widget also supports embedded images and windows.

74
Q

label

A

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
Q

regular expresion

A

use the backslash character (‘') to indicate special forms or to allow special characters to be used without invoking their special meaning.

76
Q

algorithm

A

A step-by-step process for solving a category of problems.

bug

77
Q

bug

A

An error in a program

78
Q

executable

A

Another name for object code that is ready to be executed.

79
Q

formal language

A

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
Q

compound data type

A

A data type in which the values are made up of components, or elements, that are themselves values.
default value

81
Q

dot operator

A

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
Q

namespace

A

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
Q

naming collision

A

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
Q

file system

A

A method for naming, accessing, and organizing files and the data they contain.
fully qualified name

85
Q

path

A

a sequence of directory names that specifies the exact location of a file

86
Q

modifier

A

A function or method that changes one or more of the objects it receives as parameters. Most modifiers are void.

87
Q

whitespace

A

Any of the characters that move the cursor without printing visible characters. The constant string.whitespace contains all the white-space characters.