Chapter 2 Flashcards
List 5 phases of developing a program
design the code, write the code, correct syntax errors, test program, correct logic error
a logic error is…
A logic error is a mistake that does not prevent the program from running, but causes it to produce incorrect results.
the person, group or organization that is asking you to write a program.
customer
a single task that the program must perform in order to satisfy the customer.
software requirement
a set of well-defined logical steps that must be taken to perform a task.
algorithm
fake code; informal language that has no syntax rules and is not meant to be complied or executed.
pseudocode
any data the program receives while it is running.
input
a piece of prewritten code that performs an operation.
function
the data you want displayed on screen.
argument
a sequence of characters that is used as data.
string
a name that represents a value stored in the computer’s memory
variable
data types
int (integer)
float(decimal)
str:
string
int:
integer
number with decimal
float
A(n) __________ makes a variable reference a value in the computer’s memory.
assignment statement
comment in python
#
integer division
//
raises number to a power
**
In the expression 12 + 7, the values on the right and left of the + symbol are called
operands because the symbol is the operator
This operator performs division, but instead of returning the quotient it returns the remainder
%
- A magic number is ________________.
an unexplained value that appears in a program’s code
A _ is a name that represents a value that does not change during the program’s execution.
variable signature
Programmers must be careful not to make syntax errors when writing pseudocode programs true/false
false