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

  • 1
    In the context of an algorithm, what is the function of an 'IF...THEN...ELSE' structure?
    پاسخ دهید
    (A)
    To make a decision based on a condition.
  • 2
    What type of validation is exemplified by ensuring a user enters a numerical value, not text, into a field designed for numbers?
    پاسخ دهید
    (C)
    Type Check
  • 3
    What is the primary goal of a type check?
    پاسخ دهید
    (A)
    To make sure the data entered is the correct type.
  • 4
    In the alarm clock algorithm, how does the algorithm know when to trigger the alarm sound?
    پاسخ دهید
    (B)
    When the current time equals the alarm time.
  • 5
    What are the key considerations in designing data validation methods?
    پاسخ دهید
    A
    B
    C
    D
  • 6
    Which types of data should be used to check if a program functions correctly during data entry?
    پاسخ دهید
    A
    C
    D
  • 7
    Which of the following statements are true about a linear search?
    پاسخ دهید
    A
    B
  • 8
    A type check is primarily used to validate the:
    پاسخ دهید
    (A)
    The type of data entered (e.g., numeric, text, boolean).
  • 9
    Which of these best describes the role of a check digit?
    پاسخ دهید
    (C)
    Detecting data entry mistakes.
  • 10
    Which of the following would be considered an example of extreme data?
    پاسخ دهید
    (B)
    The largest and smallest values that are valid inputs.
  • 11
    In pseudocode, what does the term 'FOR...NEXT' usually indicate?
    پاسخ دهید
    (C)
    A loop.
  • 12
    What is the role of an IF-THEN-ELSE statement in conditional statements?
    پاسخ دهید
    (D)
    To execute different code blocks based on a condition
  • 13
    Which programming stage directly follows the design stage in the program development life cycle?
    پاسخ دهید
    (B)
    Coding
  • 14
    What is the purpose of testing in the program development life cycle?
    پاسخ دهید
    (C)
    To ensure the program meets requirements.
  • 15
    In the provided algorithm, what is used to determine whether the password length is acceptable?
    پاسخ دهید
    (C)
    The `PasswordLength` is not equal to eight characters.
  • 16
    What is the purpose of data validation?
    پاسخ دهید
    (B)
    To ensure the data is accurate, reliable, and complete.
  • 17
    In the context of developing algorithms, what is the main purpose of using the appropriate data types for variables?
    پاسخ دهید
    (C)
    To prevent data errors and ensure the algorithm operates as intended.
  • 18
    What is the main objective when using "normal data" for program testing?
    پاسخ دهید
    (A)
    To verify that the program functions correctly with expected inputs.
  • 19
    In pseudocode, what does `Counter <- Counter + 1` typically represent?
    پاسخ دهید
    (C)
    Incrementing the counter by 1.
  • 20
    What is pseudocode?
    پاسخ دهید
    (B)
    A simple method for showing algorithms that is very similar to code used in a programming language.
  • 21
    What are the types of data that can be taken from a computer?
    پاسخ دهید
    (B)
    Output
  • 22
    What is the conventional sequence of operations applied in check digit calculation?
    پاسخ دهید
    (C)
    Multiplying, adding, then dividing.
  • 23
    What does a flowchart use to represent the beginning and end of an algorithm?
    پاسخ دهید
    (C)
    Terminator symbols
  • 24
    In a flowchart, what does the shape of a rectangle typically represent?
    پاسخ دهید
    (B)
    A process or action.
  • 25
    What are the key characteristics involved in searching for a specific item using a linear search?
    پاسخ دهید
    A
    D
  • 26
    Which data validation technique checks to see if a number is within a specific acceptable range?
    پاسخ دهید
    (C)
    Range check.
  • 27
    Which of the following best describes decomposition in the context of problem-solving?
    پاسخ دهید
    (B)
    Breaking down a complex problem into smaller, more manageable parts.
  • 28
    What type of shape is used in a flowchart to indicate the start or end point?
    پاسخ دهید
    (C)
    Oval
  • 29
    What steps are commonly involved in bubble sort?
    پاسخ دهید
    A
    B
    C
  • 30
    Which of the following is the primary purpose of a screen/visual check in data validation?
    پاسخ دهید
    (A)
    To provide the user a chance to check the accuracy of the entered data.
  • 31
    What type of check ensures that the entered data contains an appropriate number of characters?
    پاسخ دهید
    (C)
    Length check
  • 32
    Which of the following is an advantage of using pseudocode?
    پاسخ دهید
    A
    D
  • 33
    What does 'top-down design' typically involve?
    پاسخ دهید
    (B)
    Breaking down the program into smaller sub-systems.
  • 34
    What is the purpose of the design stage in the program development life cycle?
    پاسخ دهید
    (B)
    Defining how the program will work, its components, and their relationships.
  • 35
    In an algorithm, what do conditional statements primarily help with?
    پاسخ دهید
    (B)
    Executing different actions based on certain conditions.
  • 36
    What symbols are used in the flowchart to show the input of data and output of information?
    پاسخ دهید
    (B)
    Parallelogram
  • 37
    In the program development life cycle, what stage typically follows the design stage?
    پاسخ دهید
    (B)
    Coding
  • 38
    What is a key characteristic of extreme data?
    پاسخ دهید
    (B)
    They are the minimum and maximum values.
  • 39
    What do trace tables provide during algorithm analysis?
    پاسخ دهید
    (B)
    Step-by-step variable changes during execution.
  • 40
    During which stage of the program development life cycle is the actual code written?
    پاسخ دهید
    (C)
    Coding
  • 41
    What is the purpose of using a `CASE OF` structure in an algorithm?
    پاسخ دهید
    (B)
    To select one action from several choices.
  • 42
    What process does a check digit typically follow?
    پاسخ دهید
    (C)
    Multiply, add, divide
  • 43
    Which loop structure is most suitable when the number of iterations is unknown and depends on a condition?
    پاسخ دهید
    (C)
    WHILE...DO...ENDWHILE
  • 44
    What is the primary purpose of a format check in the context of data validation?
    پاسخ دهید
    (B)
    To ensure the data conforms to a specific pattern.
  • 45
    Which of the following best describes the main purpose of a check digit?
    پاسخ دهید
    (B)
    To detect common errors that may occur during data entry.
  • 46
    In the bubble sort algorithm, how is the sorting achieved?
    پاسخ دهید
    (A)
    By comparing and swapping adjacent elements.
  • 47
    What does the `THEN` keyword typically introduce in an `IF...THEN...ELSE` structure?
    پاسخ دهید
    (B)
    The set of actions to be taken if the condition is true.
  • 48
    What sequence of operations is common in check digit calculations?
    پاسخ دهید
    (A)
    Multiply, add, and divide.
  • 49
    What are typical elements that are included in a good validation process?
    پاسخ دهید
    A
    B
    C
  • 50
    Which data is used to make sure a program handles incorrect inputs well?
    پاسخ دهید
    (B)
    Abnormal Data