Computer Science for IGCSE & O level - Algorithm Design And Problem Solving (Section 6)
1
Which of the following is a key feature of good algorithm design?
2
In the context of pseudocode for calculating ticket prices, what would cause the 'Discount' to be 0.2?
3
What is meant by the term 'modularity' in the context of algorithm design?
პასუხი(B)
The decomposition of an algorithm into smaller, independent modules.
4
Which type of check would be most useful to test if someone entering a date formatted incorrectly?
5
What is the main benefit of using subroutines (or procedures) in an algorithm?
პასუხი(C)
They promote code reusability and organization.
6
In the context of algorithms, what does 'efficiency' primarily refer to?
პასუხი(A)
The speed at which the algorithm produces results.
7
During which phase of the program development life cycle would you write the program code?
8
What is the main goal of using a 'modular' approach in programming?
პასუხი(C)
To break the code into manageable pieces to enhance code organization and reusability.
9
Which of these is an example of a selection control structure?
10
Which symbol is used to represent a decision in a flowchart?
11
Which of the following methods involves finding the largest and smallest values in a set of data?
პასუხი(C)
Finding maximum, minimum and average
12
What type of data should be used to test if a program works at the limits of what the software is designed for?
13
In programming, what does the term 'debugging' mean?
პასუხი(B)
To fix errors or bugs in a program.
14
What is abstraction in the context of program design?
პასუხი(A)
Hiding irrelevant details to focus on essential elements.
15
What is the purpose of a trace table in algorithm design?
პასუხი(D)
To trace the values through an algorithm for given inputs
16
In a flowchart, which symbol is used to show the input and output?
17
What is the main goal of 'testing' an algorithm?
პასუხი(B)
To verify that the algorithm is correct and functioning as expected.
18
What is an appropriate check to validate the number of tickets?
19
Which of the following is NOT a component of a computer system?
20
What is 'Input' in the context of a computer system?
პასუხი(D)
Where the system gets the data
21
What are the two types of conditional statements as mentioned in the text?
22
Which loop structure is best used when the number of iterations is known before the loop starts?
23
What is the purpose of a 'loop' in an algorithm?
პასუხი(B)
To repeat a set of instructions.
24
What is the primary advantage of using a FOR loop over a WHILE loop?
პასუხი(B)
It automatically manages a counter.
25
In a concert ticket sales example, what percentage of discount is applied when tickets are bought in bulk?
26
Which of the following is an example of a control structure?
27
Which of the following are standard methods used in algorithm design?
28
What is the best approach to handle an input validation check that fails?
29
What does the term 'algorithm' mean?
პასუხი(B)
A set of instructions for solving a problem.
30
What is a 'logical error' in programming?
პასუხი(C)
An error that leads to unexpected results due to incorrect logic.
31
What type of error would a syntax error in an algorithm cause?
32
Which data structure uses the LIFO (Last-In, First-Out) principle?
33
Which of the following are steps involved in writing and amending an algorithm?
34
What type of data validation check ensures data is within a defined range?
35
What kind of data is typically used to identify errors in an algorithm?
36
What is the purpose of a 'function' or 'procedure' in programming?
პასუხი(C)
To perform a specific task or calculation.
37
What does an algorithm define?
პასუხი(B)
The solution to a problem
38
What kind of errors could be discovered using trace tables?
39
What are the benefits of using functions in programming?
40
What is the main role of the 'REPEAT ... UNTIL' loop?
პასუხი(A)
To execute code until a specific condition is true.
41
In the concert ticket sales example, what condition is checked before applying the discount?
პასუხი(B)
Whether the number of tickets is greater than or equal to 20.
42
What is the purpose of a trace table in algorithm design?
პასუხი(C)
To record the algorithm's state at various points.
43
What is the difference between an algorithm and a program?
პასუხი(C)
An algorithm is the design or blueprint, and a program is the implementation of that design.
44
What is a 'flowchart' used for?
პასუხი(B)
To represent an algorithm visually using symbols.
45
What action does the algorithm involving an alarm clock perform?
პასუხი(C)
It waits for a specific time and then outputs a sound.
46
When testing a program, what is the primary objective of using "normal data"?
პასუხი(A)
To determine how the program functions with common and expected inputs.
47
Which validation techniques offer a human-based review of entered data?
48
Which of the following are standard validation checks?
49
Which of the following is an example of a format check?
პასუხი(A)
Ensuring an email address contains an '@' symbol.
50
What are some of the potential problems related to entering a date into the input data?