Computer Science for IGCSE & O level - Algorithm Design And Problem Solving (Section 11)

  • 1
    Which of the following is NOT a common method of verification?
    Одговорити
    (C)
    Type check
  • 2
    What is the purpose of the outermost `FOR` loop in the bubble sort example (i.e., `FOR Index <- 1 TO Length - 1`)?
    Одговорити
    (B)
    To control the number of passes through the list.
  • 3
    To test a program for a salary range, from a minimum to a maximum, which data type is most relevant?
    Одговорити
    (D)
    Extreme data
  • 4
    When testing a program that calculates an employee's pay, which type of test data should you employ to verify the correct handling of the minimum (e.g., 0 hours worked) and maximum possible hours worked?
    Одговорити
    (D)
    Extreme data
  • 5
    In the context of algorithm design, what does the term "verification" primarily refer to?
    Одговорити
    (C)
    Checking that data has been accurately copied from one source to another.
  • 6
    Which validation techniques involve a human user checking the data?
    Одговорити
    B
    C
  • 7
    In a typical `FOR...TO...NEXT` loop, what happens after the `NEXT` statement is executed?
    Одговорити
    (B)
    The loop variable is incremented, and the loop starts again.
  • 8
    In pseudocode, what do you use to assign a value to an item/variable?
    Одговорити
    (C)
    The <- sign
  • 9
    To test the boundaries of a program, what data is used?
    Одговорити
    (C)
    Boundary data
  • 10
    What are the essential components of data validation techniques?
    Одговорити
    A
    B
    C
  • 11
    Which of the following is a type of validation check?
    Одговорити
    (D)
    Character check.
  • 12
    When sorting data using a bubble sort, the data is typically sorted in which order?
    Одговорити
    (B)
    Ascending or descending order.
  • 13
    What does the 'searching using a linear search' standard method of solution involve?
    Одговорити
    (A)
    Comparing each item in a list against a target value until it is found or the end of the list is reached.
  • 14
    Which of the following is generally a step in the algorithm design process?
    Одговорити
    A
    B
    D
  • 15
    What does the algorithm 'totaling' usually aim to achieve?
    Одговорити
    (B)
    Calculating the sum of a set of values.
  • 16
    When should a WHILE...DO...ENDWHILE loop be used?
    Одговорити
    (B)
    When the number of iterations is not known and the action must be repeated until a certain condition is met.
  • 17
    What is the purpose of the design stage in software development?
    Одговорити
    (C)
    To plan the program's structure and components.
  • 18
    What are the different types of checks that a program might include for validation?
    Одговорити
    A
    B
    D
  • 19
    What aspect of an algorithm is most effectively illustrated through the use of a trace table?
    Одговорити
    (C)
    The step-by-step execution flow and how variables change.
  • 20
    Which types of data are used to determine if a program works correctly?
    Одговорити
    A
    B
    C
    D
  • 21
    Check digits mainly help with...
    Одговорити
    (B)
    Spotting data entry mistakes.
  • 22
    In the bubble sort example, what would the `Temperature[Index] <= Temperature[Index + 1]` represent?
    Одговорити
    A
    D
  • 23
    Which checks are examples of the verification process?
    Одговорити
    B
    C
  • 24
    What is the purpose of a 'bubble sort' algorithm?
    Одговорити
    (B)
    To sort a list of items.
  • 25
    What is the role of flowlines in a flowchart?
    Одговорити
    (B)
    To specify the sequence of steps in the algorithm.
  • 26
    In the `CASE OF` structure, how are the different code blocks selected for execution?
    Одговорити
    (C)
    Based on the value of an expression.
  • 27
    What does the 'storage' component of a computer system refer to?
    Одговорити
    (C)
    The data that needs to be stored for future use.
  • 28
    What kind of input does the algorithm for validating the percentage mark use?
    Одговорити
    (B)
    An integer.
  • 29
    In the context of the alarm clock algorithm, what is the expected behavior of the code within the WHILE loop?
    Одговорити
    (B)
    To repeatedly monitor the time until the condition is met.
  • 30
    What is the primary purpose of a structure diagram when designing an algorithm?
    Одговорити
    (D)
    To provide a high-level overview of the algorithm's components and their relationships.
  • 31
    What is a key characteristic of an 'algorithm'?
    Одговорити
    A
    B
    C
  • 32
    What is the role of a presence check in data validation?
    Одговорити
    (A)
    To ensure data is entered into a field.
  • 33
    Which of the following is a valid use of the CASE structure?
    Одговорити
    (B)
    To display different messages based on a user's input.
  • 34
    What is the role of a structure diagram?
    Одговорити
    (B)
    To visualise and document the structure of the software.
  • 35
    In the context of algorithms, what are the typical components of a loop structure?
    Одговорити
    A
    B
    C
    D
  • 36
    When using a linear search to find an item in an unsorted list, what is the worst-case scenario?
    Одговорити
    (B)
    The item is not in the list.
  • 37
    In algorithm design, what is the significance of the step that involves ‘constructing your algorithm’?
    Одговорити
    (C)
    To ensure that the algorithm functions correctly and that it will execute.
  • 38
    What is the purpose of an algorithm?
    Одговорити
    (B)
    To solve a specific problem.
  • 39
    What is the role of a CASE OF statement?
    Одговорити
    (A)
    To choose between many values
  • 40
    In the context of data validation, what is a screen/visual check primarily used for?
    Одговорити
    (C)
    To allow the user to visually confirm the data they've entered is correct.
  • 41
    Why is boundary data used in the testing phase?
    Одговорити
    (A)
    To test the extreme limits of data input.
  • 42
    Which of the following is *not* a common type of validation check?
    Одговорити
    (D)
    Efficiency check
  • 43
    Testing an algorithm's performance with expected inputs uses...
    Одговорити
    (A)
    Normal data.
  • 44
    What is the purpose of using comments within an algorithm or its code?
    Одговорити
    (C)
    To explain the code to someone else or to yourself later.
  • 45
    What is the purpose of using flow lines within a flowchart?
    Одговорити
    (B)
    To denote the flow of execution.
  • 46
    Which of the following actions is most crucial for creating reliable algorithms?
    Одговорити
    (C)
    Thorough testing with a range of inputs.
  • 47
    What is the function of the 'ELSE' clause in an `IF...THEN...ELSE` structure?
    Одговорити
    (C)
    To define the actions to be taken when the condition is false.
  • 48
    Which type of check verifies that the data entered is a number?
    Одговорити
    (C)
    Type Check
  • 49
    Which type of check ensures the data entered is of the correct type?
    Одговорити
    (B)
    Type Check
  • 50
    What is the function of an algorithm in the context of computing?
    Одговорити
    (C)
    To provide a set of instructions for solving a specific problem.