
A Level Programming Concepts

Quiz
•
Computers
•
12th Grade
•
Medium
Mr Applewhaite
Used 2+ times
FREE Resource
20 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following pseudocode snippets correctly calculates the total of all even numbers within a range entered by the user?
low = input ("Enter the first number in the range") high = input ("Enter the last number in the range") total = 0 for n = low to high -1 if n MOD 2 == 0 then total = total + n endif next n print("Total of even numbers in the range ",total)
low = input ("Enter the first number in the range") high = input ("Enter the last number in the range") total = 0 for n = low to high if n MOD 2 == 1 then total = total + n endif next n print("Total of even numbers in the range ",total)
low = input ("Enter the first number in the range") high = input ("Enter the last number in the range") total = 0 for n = low to high -1 if n MOD 2 == 1 then total = total + n endif next n print("Total of even numbers in the range ",total)
low = input ("Enter the first number in the range") high = input ("Enter the last number in the range") total = 0 for n = low to high if n MOD 2 == 0 then total = total + n endif next n print("Total of even numbers in the range ",total)
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is NOT a way to make programs easy to understand and maintain?
Meaningful variable names
Comments to explain sections of the program
Modular structure
Using complex and obscure variable names
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the subroutine answerYorN if the user inputs "y"?
"Please enter y or n: "
"You must answer y or n"
"y"
"n"
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the subroutine answerYorN do if the user inputs an invalid response?
It terminates the program.
It prints "You must answer y or n" and asks for input again.
It returns the invalid response.
It skips the input and continues.
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the purpose of the subroutine answerYorN?
To calculate the average temperature.
To validate user input as either "y" or "n".
To find the highest temperature.
To complete the trace table.
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Explain the difference between passing parameters by value and by reference.
By value: The value is copied into a variable in the subroutine; By reference: The address is passed to the subroutine.
By value: The address is passed to the subroutine; By reference: The value is copied into a variable in the subroutine.
By value: The value is copied into a variable in the subroutine; By reference: The value is copied into a variable in the subroutine.
By value: The address is passed to the subroutine; By reference: The address is copied into a variable in the subroutine.
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is meant by modular programming?
Combining multiple programs into one large program.
Splitting a large program up into self-contained subroutines (modules).
Writing a program without using any subroutines.
Using only global variables in a program.
Create a free account and access millions of resources
Similar Resources on Wayground
15 questions
Excel

Quiz
•
10th - 12th Grade
15 questions
Luyện tập

Quiz
•
KG - University
21 questions
ÔN TẬP KIỂU XÂU

Quiz
•
1st - 12th Grade
20 questions
technology (Computer)

Quiz
•
3rd Grade - University
21 questions
Ôn tập cuối kì Đông. Python

Quiz
•
10th Grade - University
20 questions
QUIZ 3 MYOB XI

Quiz
•
11th - 12th Grade
18 questions
Year 9 - Lesson 1 - Spreadsheet Quiz

Quiz
•
9th Grade - University
20 questions
Programming Concepts Quiz

Quiz
•
10th Grade - University
Popular Resources on Wayground
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
10 questions
Nouns, nouns, nouns

Quiz
•
3rd Grade
10 questions
9/11 Experience and Reflections

Interactive video
•
10th - 12th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
11 questions
All about me

Quiz
•
Professional Development
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
9 questions
Tips & Tricks

Lesson
•
6th - 8th Grade
Discover more resources for Computers
20 questions
Digital Citizenship

Quiz
•
8th - 12th Grade
35 questions
Computer Baseline Examination 2025-26

Quiz
•
9th - 12th Grade
13 questions
Problem Solving Process

Quiz
•
9th - 12th Grade
10 questions
Understanding Algorithms with Pseudocode and Flowcharts

Interactive video
•
9th - 12th Grade
19 questions
AP CSP Unit 1 Review (code.org)

Quiz
•
10th - 12th Grade