Here are all the actual test exam dumps for IT exams. Most people prepare for the actual exams with our test dumps to pass their exams. So it's critical to choose and actual test pdf to succeed.

Exam PCED-30-02 Topic 1 Question 28 Discussion

Actual exam question for Python Institute's PCED-30-02 exam
Question #: 28
Topic #: 1
You have a list of test scores, where each entry includes a student name and a score. Some students appear more than once. You want to compute the average score for each student and store the results in a dictionary. Here's the partial code block:

Which code correctly replaces the # MISSING CODE comment to calculate the average score for each student? Select the best answer.

Suggested Answer: A Vote an answer

It iterates through each record, extracts the name and score, and uses dictionary .get() to accumulate total scores and counts per student safely, initializing missing keys to zero. This correctly enables calculation of each student's average afterward.

by Christian at Aug 23, 2026, 03:31 PM

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
Nick name: Submit Cancel
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.