Ch.8 Programming Flashcards

1
Q

variable

A

a named memory location that can store data
the data can change whilst a program is running

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

constant

A

a named memory location that can store data
the data cannot change whilst a program is running

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

identifier

A

a name given to a variable, constant, data structure or subroutine

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

assignment

A

a type of programming statement that stores data in a variable or constant

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

string

A

a data type (any characters including letter, numbers and/or symbols)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

data type

A

the characteristics of a piece of data
common data types: string, integer, real, boolean

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

integer

A

a data type (whole numbers)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

real

A

a data type (decimal numbers)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

single

A

a data type (decimal numbers)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

double

A

a data type (decimal numbers)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

boolean

A

a data type (true or false)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

char

A

a single character
e.g. “A”, “1”, “*”

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

casting

A

converting data from one data type to another data type

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

output

A

data that is displayed to the user usually on-screen

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

concatenation

A

joining two or more strings together

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

input

A

the user entering data into the program, usually from a keyboard

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

arithmetic operator

A

a symbol that performs a mathematical function
e.g. “+” adds two values together

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

MOD

A

remainder division
the remainder after the division is performed
e.g. MOD(5,2) = 2

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

DIV

A

integer division
the remainder from the division is ignored
e.g. DIV(5,2) = 2

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

parentheses

A

brackets in a mathematical statement
determine which calculations are performed first

21
Q

sequence

A

a programming construct
instructions are run once and in the order they are written

22
Q

selection

A

a programming construct
a condition is checked and this determines which code is run, or not run

23
Q

IF statement

A

a type of selection construct where the result of the condition is either true or false

24
Q

CASE statement

A

a type of selection construct where there is a list of different values to compare a single value against

25
logical operator
a symbol that performs a comparison resulting in true or false
26
boolean operator
a symbol that joins multiple logical comparisons e.g. AND, OR, NOT
27
AND operator
returns true when both inputs are true
28
NOT operator
returns true if the input is false, and false if it is true
29
OR operator
returns true when one, or both, inputs are true
30
iteration
a programming construct code is run multiple times
31
loop
a type of iteration code is run a finite number of times, usually a for loop
32
count-controlled loop
a type of iteration code is run a finite number of times, usually a for loop
33
pre-condition loop
a type of iteration code is run while the condition is true the condition is checked before running any code in the loop, so the code might never run
34
post-condition loop
a type of iteration code is run until a condition is true the condition is checked after the code in the loop is run, so the code always runs once
35
totalling
a type of program adds up multiple values to find the total
36
counting
a type of program adds one for every item to find out how many there are
37
nested statement
a construct (selection or iteration) that is inside another construct
38
subroutine
a self-contained piece of code that has an identifier and can be called from elsewhere in a program
39
procedure
a subroutine that does not return a value to the program that called it
40
function
a subroutine that does return a value to the program that called it
41
parameter
a value that is sent to a subroutine
42
scope
the sections in the code where the variable, or constant, can be accessed
43
global scope
the variable or constant can be assessed from any part of the program
44
local scope
the variable or constant can only be accessed in the subroutine it is declared within
45
array
a data structure where you can store multiple data items, of the same data type, under one identifier
46
1-dimensional array
an array that has only one index
47
index
the number of the space in the array
48
2-dimensional array
an array that has two indices
49
file handling
programming statements that allow text files to be opened, read from, written to and closed