No student devices needed. Know more
25 questions
What is the purpose of the above flow diagram shape?
Start/Stop
Input
Process
Decision
What is the purpose of the above flow diagram shape?
Start/Stop
Input
Process
Decision
What is the purpose of the above flow diagram shape?
Start/Stop
Input
Process
Decision
Which of the following best describes pseudo-code?
A sub program that carries out a list of instructions.
A set of instructions in the style of a programming language but written in plain English.
A data structure that contains one type of data, similar to a list.
A data structure that contains columns of data, similar to a table.
Which of the following best describes a one-dimensional array?
A sub program that carries out a list of instructions.
A set of instructions in the style of a programming language but written in plain English.
A data structure that contains one type of data, similar to a list.
A data structure that contains columns of data, similar to a table.
Which of the following best describes a two-dimensional array?
A sub program that carries out a list of instructions.
A set of instructions in the style of a programming language but written in plain English.
A data structure that contains one type of data, similar to a list.
A data structure that contains columns of data, similar to a table.
Which of the following is the best data type for a variable called "telephoneNumber"?
string
char or character
Boolean
integer
Which of the following is the best data type for a variable called "studentNumber"?
string
char or character
Boolean
integer
Which of the following is the best data type for a variable called "averageNumber"?
string
real
Boolean
integer
Which of the following is NOT an arithmetic operator?
+
==
*
/
Which of the following is NOT a comparison operator?
+
==
!=
>=
What is the purpose of Casting?
Change the data type of a variable, for example num1 = str
Change the format of a variable to upper case, for example name.upper()
Change the format of a variable to lower case, for example email.lower()
Change a variable into code, for example name.substring(2,3)
Which of the following is NOT an example of string manipulation?
Change the data type of a variable, for example num1 = str
Change the format of a variable to upper case, for example name.upper()
Change the format of a variable to lower case, for example email.lower()
Change a variable into code, for example name.substring(2,3)
What does the following code do:
x.length
Changes all the characters in a variable to lower case.
Changes all the characters in a variable to upper case.
Extracts a specific character from a string.
Returns the number of characters in a string.
What does the following code do:
x.subString(2,3)
Changes all the characters in a variable to lower case.
Changes all the characters in a variable to upper case.
Extracts a specific character from a string.
Returns the number of characters in a string.
What does the following code do:
x.lower()
Changes all the characters in a variable to lower case.
Changes all the characters in a variable to upper case.
Extracts a specific character from a string.
Returns the number of characters in a string.
A constant is a value within a program that does not change. Which of the following would be a good example of a constant?
age
year
area
pi
What is the correction for the error in the code?
if age <= 18:
if age != 18:
if age >= 18:
if age = 18:
What is the difference between a While Loop and a For Loop?
A For Loop continues to run for a specific number of times, for example for x in range (0,3):
A While Loop continues to run until a condition is met, for example while x>0:
Both of these.
Neither of these.
What is the purpose of the following code:
if x == True AND y == True . . . then
To check if two variables are both True
To check if two variables are both False
To check if one variable only is True
To check if one variable only is False
What is the purpose of the following code:
if x == True OR y == True . . . then
To check if at least one variable is True
To check if at least one variable is False
To check if one variable only is True
To check if one variable only is False
Which of the following symbols means NOT?
!=
>
<
=
Which of the following symbols is an assignment operator?
!=
>
<
=
Fill in the blanks:
True
False
t
1
Why should a global variable not be used when programming?
It is a variable that can only be updated within a subprogram or subroutine.
It is a variable that can be called at any point within a program, meaning that it can be changed throughout the program sometimes by mistake.
It is a value that does not change in a program, for example VAT.
It is a method of sorting data by finding the mid-point and dividing the data by 2.
Explore all questions with a free account