Make Way for Ducklings: Traversal and the
abecedarian: Traversal and the
abstract class: Glossary
abstract data type|see{ADT): Abstract data types
access: Accessing elements
addition, fraction: Fraction addition
ADT: Abstract data types, Clients and providers, Glossary
ADT, Priority Queue: 19, Priority queue
ADT, Queue: 19, The Queue ADT
ADT, Stack: The Stack ADT
algorithm: Glossary, Algorithms, Glossary
aliasing: Aliasing, Glossary, Aliasing and copying, Copying
ambiguity: Formal and natural languages, Sameness
ambiguity, fundamental theorem: The fundamental ambiguity theorem
animal game: The animal tree
argument: Function calls, Parameters and arguments, Glossary
arithmetic sequence: Tables
assignment: Variables, Glossary, Multiple assignment
assignment operator: Glossary
assignment, multiple : Glossary
assignment, tuple: Tuple assignment, Glossary
attribute: Attributes, Glossary
AttributeError: When I run the program I get an exception.
base case: Stack diagrams for recursive functions, Glossary
binary operator: Expression trees, Glossary
binary tree: 20, Glossary
block: Conditional execution, Glossary
body: Conditional execution, Glossary
body, loop: The
boolean expression: Boolean expressions, Glossary
boolean function: Boolean functions
bracket operator: A compound data type
branch: Alternative execution, Glossary
break statement: 11, Glossary
bug: What is debugging?, Glossary
byte code: Glossary
call graph: Hints
call, function: Function calls
cargo: Embedded references, Glossary, 20
chained conditional: Chained conditionals
character: A compound data type
character classification: Character classification
child node: 20, Glossary
circular buffer: Glossary
circular definition: More recursion
class: 12, Glossary
class, Golfer: The
class, LinkedList: The
class, Node: The
class, Stack: Implementing stacks with Python lists
classification, character: Character classification
client: Abstract data types, Glossary
clone: Glossary
cloning: Cloning lists, Aliasing and copying
coercion: Glossary
coercion, type: Type coercion, Long integers
collection: Lists as collections, The Stack ADT
column: Matrixes
comment: Comments, Glossary
comparison, fraction: Comparing fractions
comparison, string: String comparison
compile: The Python programming language, Glossary
compile-time error: A
compiler: Syntax errors
complete language: More recursion
composition: Composition, Glossary, Composition, Composition
compound data type: A compound data type, Glossary, User-defined compound types
compound statement: Conditional execution, Glossary
compound statement, body: Conditional execution
compound statement, header: Conditional execution
compound statement, statement block: Conditional execution
compression: Counting letters
computational pattern: A
concatenation: Operations on strings, Glossary, Traversal and the, Strings are immutable
concatenation, list: List operations
condition: Glossary, The, Infinite Loop
conditional branching: Conditional execution
conditional execution: Conditional execution
conditional statement: Glossary
conditional, chained: Chained conditionals
constant time: Performance characteristics, Glossary
constructor: User-defined compound types, Glossary
continue statement: Text files, Glossary
converstion, type: Type conversion
copy module: Copying
copying: Aliasing and copying, Copying
counter: Looping and counting, Glossary
counting: Counting, Counting letters
cursor: Glossary
data structure, generic: Implementing stacks with Python lists, Pushing and popping
data structure, recursive: Embedded references, Glossary, 20
data type, compound: A compound data type, User-defined compound types
data type, dictionary: 10
data type, immutable: Mutability and tuples
data type, long integer: Long integers
data type, tuple: Mutability and tuples
data type, user-defined: User-defined compound types, B
dead code: Return values, Glossary
debugging: What is debugging?, Glossary, A
decrement: Glossary
deep copy: Glossary
deep equality: Sameness, Glossary
definition, circular: More recursion
definition, function: Adding new functions
definition, recursive: Building an expression tree
deletion, list: List deletion
delimiter: Glossary, Directories, Parsing, Glossary
denominator: B
deterministic: Glossary
development plan: Glossary
development, incremental: Program development, Glossary
development, planned: Glossary
dictionary: Matrixes, 10, Glossary, Writing variables, When I run the program I get an exception.
dictionary, method: Dictionary methods
dictionary, operation: Dictionary operations
directory: Directories, Glossary
divison, integer: Type coercion
documentation: Invariants
dot notation: Math functions, Glossary, Dictionary methods
Doyle, Arthur Conan: Experimental debugging
element: 8, Glossary
embedded reference: Copying, Embedded references, Glossary, 20
encapsulate: Glossary
encapsulation: Encapsulation and generalization, Objects are mutable, Abstract data types, Clients and providers
equality: Sameness
error checking: Checking types
error handling: Handling errors
error messages: Syntax errors
error, compile-time: A
error, runtime: Runtime errors, Infinite recursion, A
error, semantic: Semantic errors, A, Semantic errors
error, syntax: Syntax errors, A
escape sequence: Tables, Glossary
Euclid: Euclid's algorithm
eureka traversal: A
except statement: Exceptions, Glossary
exception: Runtime errors, Glossary, Exceptions, Glossary, A, When I run the program I get an exception.
executable: Glossary
execution, flow: Flow of Execution
expression: Operators and operands, Glossary, Using a stack to evaluate postfix
expression tree: Expression trees, Building an expression tree
expression, big and hairy: I've got a big hairy expression and it doesn't do what I expect.
expression, boolean: Boolean expressions, Glossary
factorial function: More recursion, Checking types
Fibonacci function: One more example, Hints
FIFO: 19, Glossary
file: 11, Glossary
file, text: Text files
float: Values and types
floating-point: Glossary, User-defined compound types
flow of execution: Flow of execution, Glossary, Flow of Execution
for loop: Traversal and the, Lists and
formal language: Formal and natural languages, Glossary
format operator: Writing variables, Glossary, The, When I run the program I get an exception.
format string: Writing variables, Glossary
frabjuous: More recursion
fraction: B
fraction, addition: Fraction addition
fraction, comparison: Comparing fractions
fraction, multiplication: Fraction multiplication
frame: Stack diagrams, Glossary, Stack diagrams for recursive functions, Hints
function: Adding new functions, Glossary, Functions, 13
function call: Function calls, Glossary
function definition: Adding new functions, Glossary
function frame: Stack diagrams, Glossary, Stack diagrams for recursive functions, Hints
function type, modifier: Modifiers
function type, pure: Pure functions
function, argument: Parameters and arguments
function, boolean: Boolean functions
function, composition: Composition, Composition
function, factorial: More recursion
function, math: Math functions
function, parameter: Parameters and arguments
function, recursive: Recursion
function, tuple as return value: Tuples as return values
functional programming style: Which is better?, Glossary
fundamental ambiguity theorem: Glossary
game, animal: The animal tree
gamma function: Checking types
generalization: Encapsulation and generalization, Objects are mutable, Generalization
generalize: Glossary
generic data structure: Implementing stacks with Python lists, Pushing and popping
geometric sequence: Tables
Golfer: The
greatest common divisor: Euclid's algorithm, Glossary
guardian: Glossary
handle exception: Exceptions, Glossary
handling errors: Handling errors
hanging: My program hangs.
hello world: The first program
helper method: Wrappers and helpers, Glossary
high-level language: The Python programming language, Glossary
hint: Hints, Glossary
histogram: A single-pass solution, Glossary, Counting letters
Holmes, Sherlock: Experimental debugging
identity: Sameness
immutable: Mutability and tuples
immutable string: Strings are immutable
immutable type: Glossary
implementation, Queue: The Queue ADT
improved queue: Improved Linked Queue
in operator: List membership
increment: Glossary
incremental development: Program development, Glossary, Glossary
incremental program development: Syntax errors
index: A compound data type, Glossary, Glossary, 10, When I run the program I get an exception.
index, negative: Length
IndexError: When I run the program I get an exception.
infinite list: Infinite lists
infinite loop: The, Glossary, My program hangs., Infinite Loop
infinite recursion: Infinite recursion, Glossary, Checking types, My program hangs., Infinite Recursion, See Also: recursion, infinite
infix: Using a stack to evaluate postfix, Glossary, Expression trees
inorder: Tree traversal, Tree traversal, Glossary
input: Input
instance: Instances as parameters, Instances as return values, Glossary
instance, object: User-defined compound types
instantiate: Glossary
instantiation: User-defined compound types
int: Values and types
integer: Values and types, Glossary
integer division: Operators and operands, Glossary, Type coercion
integer, long: Long integers
Intel: Tables
interface: The Stack ADT, Glossary
interpret: The Python programming language, Glossary
invariant: Invariants, Glossary
invoke: Glossary
invoking method: Dictionary methods
irrational: Taking it further
iteration: 6, The, Glossary
join function: Strings and lists
key: 10, Glossary
key-value pair: 10, Glossary
keyboard input: Input
KeyError: When I run the program I get an exception.
keyword: Variable names and keywords, Variable names and keywords, Glossary
knowledge base: The animal tree
language, : Sameness
language, complete: More recursion
language, formal: Formal and natural languages
language, high-level: The Python programming language
language, low-level: The Python programming language
language, natural: Formal and natural languages
language, programming: The Python programming language
language, safe: Runtime errors
leaf node: 20, Glossary
leap of faith: Leap of faith, Lists and recursion
length: List length
level: 20, Glossary
linear time: Performance characteristics, Glossary
link: Glossary
linked list: Embedded references, Glossary
linked queue: Linked Queue, Glossary
LinkedList: The
Linux: Experimental debugging
list: 8, Glossary, 17
list deletion: List deletion
list method: Counting letters
list operation: List operations
list traversal: Glossary
list, as parameter: List parameters, Lists as collections
list, cloning: Cloning lists
list, element: Accessing elements
list, for loop: Lists and
list, infinite: Infinite lists
list, length: List length
list, linked: Embedded references, Glossary
list, loop: Infinite lists
list, membership: List membership
list, modifying: Modifying lists
list, mutable: Lists are mutable
list, nested: List values, Nested lists, Matrixes, Sparse matrices
list, printing: Lists as collections
list, printing backwards: Lists and recursion
list, slice: List slices
list, traversal: Accessing elements, Lists as collections
list, traverse recursively: Lists and recursion
list, well-formed: Invariants
literalness: Formal and natural languages
local variable: Variables and parameters are local, Glossary, Local variables
logarithm: Tables
logical operator: Boolean expressions, Logical operators
long integer: Long integers
loop: The, Glossary
loop variable: Glossary, Lists as collections
loop, body: The, Glossary
loop, condition: Infinite Loop
loop, for loop: Traversal and the
loop, in list: Infinite lists
loop, infinite: The, Infinite Loop
loop, traversal: Traversal and the
loop, while: The
low-level language: The Python programming language, Glossary
lowercase: Character classification
math function: Math functions
mathematical operator: Fraction multiplication
matrix: Matrixes
matrix, sparse: Sparse matrices
McCloskey, Robert: Traversal and the
mental model: My program doesn't work.
method: Dictionary methods, Glossary, 13
method, dictionary: Dictionary methods
method, helper: Wrappers and helpers
method, invocation: Dictionary methods
method, list: Counting letters
method, wrapper: Wrappers and helpers
model, mental: My program doesn't work.
modifier: Modifiers, Glossary
modifying lists: Modifying lists
module: Math functions, Glossary, The
module, copy: Copying
module, string: Character classification
modulus operator: The modulus operator, Glossary
multiple assignment: Multiple assignment, Glossary
multiplication, fraction: Fraction multiplication
mutable: Strings are immutable, Glossary, Mutability and tuples
mutable type: Glossary
mutable, list: Lists are mutable
mutable, object: Objects are mutable
NameError: When I run the program I get an exception.
natural language: Formal and natural languages, Glossary, Sameness
negation: Taking it further
nested list: Nested lists, Glossary, Sparse matrices
nesting: Glossary
newline: Glossary
node: Embedded references, Glossary, 20, Glossary
Node class: The
None: Return values, Glossary
number, random: Random numbers
numerator: B
object: Objects and values, Glossary, 12, Glossary
object code: Glossary
object instance: User-defined compound types
object invariant: Invariants
object, mutable: Objects are mutable
operand: Operators and operands, Glossary
operation, dictionary: Dictionary operations
operation, list: List operations
operator: Operators and operands, Glossary
operator overloading: The
operator, assignment: Glossary
operator, binary: Expression trees, Glossary
operator, bracket: A compound data type
operator, format: Writing variables, Glossary, The, When I run the program I get an exception.
operator, in: List membership
operator, logical: Boolean expressions, Logical operators
operator, modulus: The modulus operator
operator, overloading: Fraction multiplication
order of evaluation: I've got a big hairy expression and it doesn't do what I expect.
order of operations: Order of operations
overflow: Hints
overload: Fraction multiplication
overloading, operator: The
parameter: Parameters and arguments, Glossary, List parameters, Instances as parameters
parameter, list: List parameters
parent node: 20, Glossary
parse: Formal and natural languages, Glossary, Parsing, Glossary, Building an expression tree
pass statement: Conditional execution
path: Directories
pattern: A, Looping and counting
pattern matching: Glossary
Pentium: Tables
performance: Performance characteristics
performance hazard: Glossary
pickle: Glossary
pickling: Pickling
planned development: Glossary
poetry: Formal and natural languages
pop: Pushing and popping
portability: Glossary
portable: The Python programming language
postfix: Using a stack to evaluate postfix, Glossary, Expression trees
postorder: Tree traversal, Tree traversal, Glossary
precedence: Glossary, I've got a big hairy expression and it doesn't do what I expect.
precondition: Infinite lists, Glossary
prefix: Tree traversal, Glossary
preorder: Tree traversal, Tree traversal, Glossary
print statement: The first program, Glossary, I added so many
printing, object: Attributes
priority: The
priority queue: 19, Glossary
priority queue, ADT: Priority queue
priority queueing: 19
problem-solving: Glossary
product: Building an expression tree
program: Glossary
program development, encapsulation: Encapsulation and generalization
program development, generalization: Encapsulation and generalization
program, development: Glossary
programming language: The Python programming language
prompt: Keyboard input, Glossary
prose: Formal and natural languages
prototype development: Prototype development versus planning
provider: Abstract data types, Glossary
pseudocode: Euclid's algorithm
pseudorandom: Glossary
pure function: Pure functions, Glossary
push: Pushing and popping
queue: 19, Glossary
Queue ADT: The Queue ADT
queue, improved implementation: Improved Linked Queue
queue, linked implementation: Linked Queue
queue, List implementation: The Queue ADT
queueing policy: 19, Glossary
raise exception: Exceptions, Glossary, Glossary
random number: Random numbers
rational: B
rectangle: Rectangles
recursion: Recursion, Recursion, Glossary, More recursion, Leap of faith, Traversing trees, Tree traversal
recursion, base case: Stack diagrams for recursive functions
recursion, infinite: Infinite recursion, Checking types, Infinite Recursion, See Also: infinite recursion
recursive data structure: Embedded references, Glossary, 20
recursive definition: Building an expression tree
reduce: Euclid's algorithm, Glossary
redundancy: Formal and natural languages
reference: Embedded references
reference, aliasing: Aliasing
reference, embedded: Copying, Embedded references, Glossary
regular expression: Parsing
repetition, list: List operations
return statement: The, I've got a function or method that doesn't return what I expect.
return value: Function calls, Glossary, Return values, Glossary, Instances as return values
return value, tuple: Tuples as return values
role, variable: The fundamental ambiguity theorem
root node: 20, Glossary
row: Matrixes
rules of precedence: Order of operations, Glossary
runtime error: Runtime errors, Glossary, Infinite recursion, Length, Length, Strings are immutable, Accessing elements, Mutability and tuples, Dictionary methods, Sparse matrices, Hints, 11, Writing variables, A, When I run the program I get an exception.
safe language: Runtime errors
sameness: Sameness
scaffolding: Program development, Glossary
script: Glossary
semantic error: Semantic errors, Glossary, Tuples as return values, A, Semantic errors
semantics: Semantic errors, Glossary
sequence: 8, Glossary
shallow copy: Glossary
shallow equality: Sameness, Glossary
sibling node: Glossary
singleton: Modifying lists, Wrappers and helpers, Glossary
slice: String slices, Glossary, List slices
source code: Glossary
split function: Strings and lists
Stack: Implementing stacks with Python lists
stack: The Stack ADT
stack diagram: Stack diagrams, Glossary, Stack diagrams for recursive functions
state diagram: Variables, Glossary
statement: Glossary
statement, assignment: Variables, Multiple assignment
statement, block: Conditional execution
statement, break: 11, Glossary
statement, compound: Conditional execution
statement, conditional: Glossary
statement, continue: Text files, Glossary
statement, except: Exceptions
statement, pass: Conditional execution
statement, print: The first program, Glossary, I added so many
statement, return: The, I've got a function or method that doesn't return what I expect.
statement, try: Exceptions
statement, while: The
string: Values and types, Values and types
string comparison: String comparison
string module: The, Character classification
string operation: Operations on strings
string, immutable: Strings are immutable
string, length: Length
string, slice: String slices
subexpression: Building an expression tree
sum: Building an expression tree
syntax: Syntax errors, Glossary, Syntax errors
syntax error: Syntax errors, Glossary, A
tab: Glossary
table: Tables
table, two-dimensional: Two-dimensional tables
temporary variable: Return values, Glossary, I've got a big hairy expression and it doesn't do what I expect.
text file: Text files, Glossary
theorem, fundamental ambiguity: The fundamental ambiguity theorem
token: Glossary, Parsing, Glossary, Building an expression tree
traceback: Stack diagrams, Glossary, Infinite recursion, Exceptions, When I run the program I get an exception.
traversal: Traversal and the, A, Lists and
traversal, list: Accessing elements
traverse: Glossary, Lists as collections, Lists and recursion, Priority queue, Traversing trees, Tree traversal
tree: 20
tree node: 20
tree, empty: 20
tree, expression: Expression trees, Building an expression tree
tree, traversal: Traversing trees, Tree traversal
try: Glossary
try statement: Exceptions
tuple: 9, Mutability and tuples, Tuples as return values, Glossary
tuple assignment: Tuple assignment, Glossary
Turing Thesis: More recursion
Turing, Alan: More recursion
type: Values and types, Values and types, Glossary
type checking: Checking types
type coercion: Type coercion, Long integers
type converstion: Type conversion
type, float: Values and types
type, int: Values and types
type, string: Values and types
TypeError: When I run the program I get an exception.
unary negation: Glossary
unary operator: Taking it further
underscore character: Variable names and keywords
uppercase: Character classification
user-defined data type: User-defined compound types
value: Values and types, Glossary, Objects and values
value, tuple: Tuples as return values
variable: Variables, Glossary
variable, local: Variables and parameters are local, Local variables
variable, roles: The fundamental ambiguity theorem
variable, temporary: Return values, Glossary, I've got a big hairy expression and it doesn't do what I expect.
veneer: Implementing stacks with Python lists, Glossary
while statement: The
whitespace: Character classification, Glossary
wrapper: Glossary
wrapper method: Wrappers and helpers
{\em Python Library Reference: Character classification