Chapter 8: Programming Flashcards
Definition of a variable
a named data store that contains a value that may change during the execution of a program
Definition of a constant
a named data store that contains a value that does not change during the execution of a program
Definition of declare
define the value and data type of a variable or constant
Definition of integer
a positive or negative whole number that can be used with mathematical operators
Definition of real number
a positive or negative number with a fractional part; Real numbers can be used with mathematical operators
Definition of char
a variable or constant that is a single character
Definition of string
a variable or constant that is several characters in length. Strings vary in length and may even have no characters (an empty string); the characters can be letters and/or digits and/or any other printable symbol
Definition of sequence
the order in which the steps in a program are executed
Definition of selection
allowing the selection of different paths through the steps of a program
Definition of iteration
a section of programming code that can be repeated under certain conditions
Definition of counting
keeping track of the number of times an action is performed
Definition of totalling
keeping a total that values are added to
Definition of operator
a special character or word in a programming language that identifies an action to be performed
Definition of arithmetic operator
an operator that is used to perform calculations
Definition of logical operator
an operator that is used to decide the path to take through a program if the expression formed is true or false
Definition of Boolean operator
an operator that is used with logical operators to form more complex expressions
Definition of nesting
the inclusion of one type of code construct inside another
Definition of procedure
A set of programming statements grouped together under a single name that can be called to perform a task in a program, rather than including a copy of the code every time the task is performed
Definition of function
a set of programming statements grouped together under a single name which can be called to perform a task in a program, rather than including a copy of the code every time
Definition of parameters
the variables in a procedure or function declaration that store the values of the arguments passed from the main program to a procedure or function
Definition of MOD
an arithmetic operator that returns the remainder of a division; different languages use different symbols for this operation
Definition of DIV
an arithmetic operator that returns the quotient (whole number part) of a division; different languages use different symbols for this operation
Definition of ROUND
a library routine that rounds a value to a given number of decimal places
Definition of RANDOM
a library routine that generates a random number
Definition of array
a data structure containing several elements of the same data type; these elements can be accessed using the same identifier name
Definition of index
identifies the position of an element in an array
Definition of file
a collection of data stored by a computer program to be used again