1/17
Practice flashcards covering vocabulary and core concepts from Chapter 2: Variables, Expressions, and Statements.
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai |
|---|
No analytics yet
Send a link to your students to track their progress
Constants
Fixed values such as numbers, letters, and strings whose values do not change.
Reserved Words
Specific identifiers like 'if', 'else', 'import', and 'class' that cannot be used as variable names because they have special meaning to Python.
Variable
A named place in the memory where a programmer can store data and later retrieve it using the assigned name.
Variable Naming Rules
Rules stating that names must start with a letter or underscore, consist of letters, numbers, and underscores, and are case sensitive.
Mnemonic
A memory aid; in programming, choosing variable names that help the programmer remember what is intended to be stored in them.
Assignment Statement
A statement using the = operator that evaluates an expression on the right-hand side and stores the result in a variable on the left-hand side.
Operator Precedence
The set of rules defining the order of evaluation in an expression, typically following the sequence: Parentheses, Power, Multiplication/Division, and Addition/Subtraction.
Multiplication Operator
The asterisk (∗) symbol used in Python to multiply two values.
Power Operator
The double asterisk (∗∗) symbol used in Python for exponentiation to raise a number to a power.
Remainder Operator
The percent sign ( symbol used to calculate the remainder of a division.
Concatenate
To join or put together strings using the + operator.
type()
A built-in Python function used to identify whether a value or variable is an integer, floating point number, or string.
Integers
A numeric type representing whole numbers without decimal parts, such as −14, 0, and 100.
Floating Point Numbers
A numeric type representing numbers that have decimal parts, such as 98.6 and 14.0.
int()
A built-in function used to convert a value, such as a string or float, into an integer.
float()
A built-in function used to convert a value, such as an integer or string, into a floating point number.
input()
A function that pauses program execution to read data from the user and returns that data as a string.
Comments
Text in a program starting with a hash sign (#) that is ignored by Python and used to document code or explain its purpose.