Mostrar mensagens com a etiqueta Python - Glossary. Mostrar todas as mensagens
Mostrar mensagens com a etiqueta Python - Glossary. Mostrar todas as mensagens

segunda-feira, 9 de setembro de 2013

Python - Glossary

7.11 Glossary

compound data type
A data type in which the values are made up of components, or elements, that are themselves values.
traverse
To iterate through the elements of a set, performing a similar operation on each.
index
A variable or value used to select a member of an ordered set, such as a character from a string.
slice
A part of a string specified by a range of indices.
mutable
A compound data types whose elements can be assigned new values.
counter
A variable used to count something, usually initialized to zero and then incremented.
increment
To increase the value of a variable by one.
decrement
To decrease the value of a variable by one.
whitespace
Any of the characters that move the cursor without printing visible characters. The constant string.whitespace contains all the whitespace characters.

sexta-feira, 23 de agosto de 2013

Python - Glossary

6.10 Glossary

multiple assignment
Making more than one assignment to the same variable during the execution of a program.
iteration
Repeated execution of a set of statements using either a recursive function call or a loop.
loop
A statement or group of statements that execute repeatedly until a terminating condition is satisfied.
infinite loop
A loop in which the terminating condition is never satisfied.
body
The statements inside a loop.
loop variable
A variable used as part of the terminating condition of a loop.
tab
A special character that causes the cursor to move to the next tab stop on the current line.
newline
A special character that causes the cursor to move to the beginning of the next line.
cursor
An invisible marker that keeps track of where the next character will be printed.
escape sequence
An escape character (\) followed by one or more printable characters used to designate a nonprintable character.
encapsulate
To divide a large complex program into components (like functions) and isolate the components from each other (by using local variables, for example).
generalize
To replace something unnecessarily specific (like a constant value) with something appropriately general (like a variable or parameter). Generalization makes code more versatile, more likely to be reused, and sometimes even easier to write.
development plan
A process for developing a program. In this chapter, we demonstrated a style of development based on developing code to do simple, specific things and then encapsulating and generalizing.

Python - Glossary

5.9 Glossary

fruitful function
A function that yields a return value.
return value
The value provided as the result of a function call.
temporary variable
A variable used to store an intermediate value in a complex calculation.
dead code
Part of a program that can never be executed, often because it appears after a return statement.
None
A special Python value returned by functions that have no return statement, or a return statement without an argument.
incremental development
A program development plan intended to avoid debugging by adding and testing only a small amount of code at a time.
scaffolding
Code that is used during program development but is not part of the final version.
guardian
A condition that checks for and handles circumstances that might cause an error.

Python - Glossary

4.13 Glossary

modulus operator
An operator, denoted with a percent sign (%), that works on integers and yields the remainder when one number is divided by another.
boolean expression
An expression that is either true or false.
comparison operator
One of the operators that compares two values: ==!=><>=, and <=.
logical operator
One of the operators that combines boolean expressions: andor, and not.
conditional statement
A statement that controls the flow of execution depending on some condition.
condition
The boolean expression in a conditional statement that determines which branch is executed.
compound statement
A statement that consists of a header and a body. The header ends with a colon (:). The body is indented relative to the header.
block
A group of consecutive statements with the same indentation.
body
The block in a compound statement that follows the header.
nesting
One program structure within another, such as a conditional statement inside a branch of another conditional statement.
recursion
The process of calling the function that is currently executing.
base case
A branch of the conditional statement in a recursive function that does not result in a recursive call.
infinite recursion
A function that calls itself recursively without ever reaching the base case. Eventually, an infinite recursion causes a runtime error.
prompt
A visual cue that tells the user to input data.

Python - Glossary

3.13 Glossary

function call
A statement that executes a function. It consists of the name of the function followed by a list of arguments enclosed in parentheses.
argument
A value provided to a function when the function is called. This value is assigned to the corresponding parameter in the function.
return value
The result of a function. If a function call is used as an expression, the return value is the value of the expression.
type conversion
An explicit statement that takes a value of one type and computes a corresponding value of another type.
type coercion
A type conversion that happens automatically according to Python's coercion rules.
module
A file that contains a collection of related functions and classes.
dot notation
The syntax for calling a function in another module, specifying the module name followed by a dot (period) and the function name.
function
A named sequence of statements that performs some useful operation. Functions may or may not take arguments and may or may not produce a result.
function definition
A statement that creates a new function, specifying its name, parameters, and the statements it executes.
flow of execution
The order in which statements are executed during a program run.
parameter
A name used inside a function to refer to the value passed as an argument.
local variable
A variable defined inside a function. A local variable can only be used inside its function.
stack diagram
A graphical representation of a stack of functions, their variables, and the values to which they refer.
frame
A box in a stack diagram that represents a function call. It contains the local variables and parameters of the function.
traceback
A list of the functions that are executing, printed when a runtime error occurs.

Python - Glossary

2.11 Glossary

value
A number or string (or other thing to be named later) that can be stored in a variable or computed in an expression.
type
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 string).
floating-point
A format for representing numbers with fractional parts.
variable
A name that refers to a value.
statement
A section of code that represents a command or action. So far, the statements you have seen are assignments and print statements.
assignment
A statement that assigns a value to a variable.
state diagram
A graphical representation of a set of variables and the values to which they refer.
keyword
A reserved word that is used by the compiler to parse a program; you cannot use keywords like ifdef, and while as variable names.
operator
A special symbol that represents a simple computation like addition, multiplication, or string concatenation.
operand
One of the values on which an operator operates.
expression
A combination of variables, operators, and values that represents a single result value.
evaluate
To simplify an expression by performing the operations in order to yield a single value.
integer division
An operation that divides one integer by another and yields an integer. Integer division yields only the whole number of times that the numerator is divisible by the denominator and discards any remainder.
rules of precedence
The set of rules governing the order in which expressions involving multiple operators and operands are evaluated.
concatenate
To join two operands end-to-end.
composition
The ability to combine simple expressions and statements into compound statements and expressions in order to represent complex computations concisely.
comment
Information in a program that is meant for other programmers (or anyone reading the source code) and has no effect on the execution of the program.