Examers.io
ExamsOrganizationsHow it worksPricingHelp & FAQ
Python Institute logo

Python InstitutePCAP - Certified Associate Python Programmer

Domain 5Objective 1

PCAP-31-03 5.1 Build Complex Lists Using List Comprehensions PCAP-31 Practice Questions (Page 7)

Part of the Miscellaneous (List Comprehensions, Lambdas, Closures, I/O) domain, which accounts for 22% of the PCAP-31 exam. Python Institute does not publish an official question count, but from its 65-minute exam (~25–45 total, ~6–10 in this domain), expect 1–2 from this objective — we provide 43 practice questions to prepare you well beyond it. (estimate)

43questions here
9free pages
2concepts
22%of the exam

Questions 31–35

  1. 31expert · medium

    A developer is working with a list of dictionaries, each with keys 'name' and 'score'. They need a list of names of students who scored above 80, sorted alphabetically. Which comprehension and sort combination achieves this?

    Select an answer first
  2. 32expert · medium

    A developer has a list of lists, where each inner list contains integers. They want to create a new list where each inner list is replaced by the sum of its elements, but only for inner lists that have a sum greater than 10. Which comprehension achieves this?

    Select an answer first
  3. 33expert · medium

    A developer is generating a list of all numbers from 1 to 100 that are perfect squares. They want to use a list comprehension. Which comprehension correctly identifies perfect squares?

    Select an answer first
  4. 34expert · medium

    A developer has a list of strings and wants to create a list of lists, where each inner list contains the characters of each string, but only for strings that have length greater than 3. Which comprehension achieves this?

    Select an answer first
  5. 35expert · medium

    A developer is working with a list of numbers and needs to create a list of tuples (number, square) for numbers that are odd. Which comprehension correctly does this?

    Select an answer first
Finished these 5 questions?

Review the revealed explanations, or continue through the curriculum.

Free Basic Practice is a study aid with revealable answers — not a scored exam. Examers.io is independent and not affiliated with or endorsed by Python Institute. “PCAP-31” is a trademark of its owner, used for identification only.