Skip to the content.

My MCQ for Trimester 2 Corrections.

This is a Jupyter Notebook where I blog my MCQ corrections.

Reflection: Based on this MCQ I feel that I have some studying to do for the CSP AP exam. However, compared to the beginning of the year where I practically failed the MCQ, I did much much better this time around, and I am very proud of it.

Analytics of Commonly Missed/Correct MCQ Questions:

Image

Question 6:

The following programs are each intended to move the robot to the gray square. Program II uses the procedure GoalReached, which returns true if the robot is in the gray square and returns false otherwise.

Program 1:

REPEAT 2 TIMES
    MOVE_FORWARD
    ROTATE_LEFT
    MOVE_FORWARD
    MOVE_FORWARD
    ROTATE_RIGHT

Program 2:

REPEAT UNTIL GoalReached
    IF CAN_MOVE forward
        MOVE_FORWARD
    ELSE
        ROTATE_LEFT

Which of the following statements best describes the correctness of the programs?

A) Program I correctly moves the robot to the gray square, but program II does not.
B) Program II correctly moves the robot to the gray square, but program I does not.
C) Both program I and program II correctly move the robot to the gray square.
D) Neither program I nor program II correctly moves the robot to the gray square.

Answer B

Incorrect. Program I correctly moves the robot to the gray square by repeatedly moving the robot forward, rotating left, moving forward twice, and rotating right.

Question 12:

What is the binary RGB triplet for the color indigo?

A) (00100101, 00000000, 10000010)
B) (00100101, 00000000, 01000001)
C) (01001011, 00000000, 10000010)
D) (01001011, 00000000, 01000001)

Answer A

Incorrect. The decimal equivalent of this triplet is (37, 0, 130).

Question 19:

Which of the following best describes the growth in the number of registered users for the first eight years of the application’s existence?

A) The number of registered users increased at about a constant rate each year for all eight years.
B) The number of registered users increased at about a constant rate for years 1 to 5 and then about doubled each year after that.
C) The number of registered users about doubled each year for years 1 to 5 and then increased at about a constant rate after that.
D) The number of registered users about doubled each year for all eight years.

Answer A

Incorrect. While the number of registered users appears to have grown at a constant rate for years 5 to 8, the number of registered users roughly doubled each year for years 1 to 5.

Question 20:

Which of the following best describes the average amount of data stored per user for the first eight years of the application’s existence?

A) Across all eight years, the average amount of data stored per user was about 10 GB.
B) Across all eight years, the average amount of data stored per user was about 100 GB.
C) The average amount of data stored per user appears to increase by about 10 GB each year.
D) The average amount of data stored per user appears to increase by about 100 GB each year.

Answer C

Incorrect. The two line graphs are roughly the same shape, indicating that the average amount of data stored per user remained about the same across all eight years.

Question 22:

Answer C

Incorrect. This code simulates a spinner with the wrong probabilities. It should have a chance for "Move 1 space," "Move 2 spaces," and "Lose a turn" in the correct order.

Question 23:

Answer B

Incorrect. This expression sets "available" to true when either condition is true, while the flowchart requires both conditions to be true.

Question 33:

A student’s overall course grade is based on their individual assignment scores, calculated by dropping the lowest score and averaging the remaining scores.

Given the following information: student name, ID number, number of assignments, average score before dropping the lowest, and course grade after dropping the lowest, which of the following cannot be determined?

A) The value of the highest assignment score
B) The value of the lowest assignment score
C) The change in course grade as a result of dropping the lowest score
D) The proportion of students who improved their course grade

Answer B

Incorrect. The lowest assignment score can be determined by calculating the difference between the total score before and after dropping the lowest.

Question:

The following procedure is intended to return the value of x times y, where x and y are integers. Multiplication is implemented using repeated additions.

The procedure code:

  • PROCEDURE Multiply(x, y):
  • count ← 0
  • result ← 0
  • REPEAT UNTIL count ≥ y:
    • result ← result + x
    • count ← count + 1
  • RETURN result

For which of the following procedure calls does the procedure NOT return the intended value?

A) Multiply(2, 5)
B) Multiply(2, -5)
C) Multiply(-2, 5)
D) Multiply(-2, -5)

Answer C

Incorrect. For these values, the procedure repeatedly adds -2 to the result five times, resulting in the intended product -10.

Question:

Consider two lists, list1 and list2. A programmer wants to determine how many different values appear in both lists. For example, if list1 contains [10, 10, 20, 30, 40, 50, 60] and list2 contains [20, 20, 40, 60, 80], there are three different values (20, 40, and 60).

The programmer has the following procedures available:

  • Combine(myList1, myList2): Combines two lists into one, e.g., [2, 4, 6] and [1, 5] become [2, 4, 6, 1, 5].
  • RemoveAllDups(myList): Removes duplicates from a list, e.g., [3, 2, 4, 2, 5, 6] becomes [3, 2, 4, 5, 6].

Which of the following can be used to assign the intended value to count?

A)
  • bothList = Combine(list1, list2)
  • uniqueList = RemoveAllDups(bothList)
  • count = LENGTH(bothList) - LENGTH(uniqueList)
B)
  • newList1 = RemoveAllDups(list1)
  • newList2 = RemoveAllDups(list2)
  • bothList = Combine(newList1, newList2)
  • count = LENGTH(list1) + LENGTH(list2) - LENGTH(bothList)
C)
  • newList1 = RemoveAllDups(list1)
  • newList2 = RemoveAllDups(list2)
  • bothList = Combine(newList1, newList2)
  • count = LENGTH(newList1) + LENGTH(newList2) - LENGTH(bothList)
D)
  • newList1 = RemoveAllDups(list1)
  • newList2 = RemoveAllDups(list2)
  • bothList = Combine(newList1, newList2)
  • uniqueList = RemoveAllDups(bothList)
  • count = LENGTH(bothList) - LENGTH(uniqueList)

Answer C

Incorrect. For example, if list1 contains [10, 10, 20, 30, 40, 50, 60] and list2 contains [20, 20, 40, 60, 80], the calculation leads to an incorrect result.

Here are the areas where I can improve based on my MCQ results:

  1. Skill 2.B - Binary Representation I struggled with questions about binary sequences and color representations. I need to practice converting between binary and decimal and work on bit sequences, especially for data like colors.

  2. Skill 4.B - Algorithms and Loops I missed questions on algorithms, particularly those involving loops. I need to improve my understanding of how loops work and practice debugging algorithms, especially with string manipulation and repeated operations.

  3. Skill 3.B - Algorithm Behavior Questions about execution times and selection statements were challenging. I need to analyze algorithms’ performance, compare them, and understand time complexity better.

  4. Skill 5.B - Data Analysis I need more practice with analyzing data, such as calculating averages and interpreting real-world data in code.

  5. Skill 1.D - Error Handling I missed questions on debugging errors. I should practice recognizing common errors in loops, indexing, and data structure manipulation and improve my flowcharting skills to prevent mistakes.

  6. Skill 3.C - Data Structures I struggled with data structure questions. I need to work on using data structures like lists and arrays to represent and manipulate data efficiently.

Next Steps: I’ll practice solving problems in these areas, use visual aids to help with binary conversion, and work on debugging techniques and algorithm comparisons. With more practice, I’ll improve my understanding and performance.