PYTHON INSTITUTE · PCAP-31-03

Python Institute PCAP-31-03 Exam Practice Questions

129 questionsInstant PDF downloadUpdated September 2026

US$39

Try 10 questions free

Card, Apple Pay or Google Pay. Your PDF is sent by email as soon as you check out.

Pass or your money backFail the exam after using this pack and we refund it. How the guarantee works
Category:
TRY BEFORE YOU BUY

Three of the 129 questions in this pack

Question 1

What is true about Python packages? (Choose two.)

  1. a code designed to initialize a package’s state should be placed inside a file named init.py
  2. a package’s contents can be stored and distributed as an mp3 file
  3. __pycache__ is a folder that stores semi-compiled Python modules
  4. the sys.path variable is a list of strings
Show answer and explanation

Correct answer: C, D

C. __pycache__ is a folder that stores semi-compiled Python modules D. the sys.path variable is a list of strings Option C is correct: __pycache__ is a directory created by Python to store bytecode (.pyc files) for faster module loading. Option D is correct: sys.path is a list of strings representing directories where Python searches for modules. Option A is incorrect because the initialization file is __init__.py (with double underscores), not init.py. Option B is incorrect because packages are distributed as archives (zip, tar, etc.) or via package managers, not as mp3 files.

Why the other options are wrong

  • A. The correct filename is __init__.py with double underscores on both sides, not init.py.
  • B. Packages are distributed as archives or via package managers like pip, never as mp3 audio files.

Question 2

What is the expected output of the following code? import sys import math b1 = type(dir(math)) is list b2 = type(sys.path) is list print(b1 and b2)

  1. None
  2. True
  3. 0
  4. False
Show answer and explanation

Correct answer: B. True

The dir() function returns a list of attributes, so type(dir(math)) is list evaluates to True. The sys.path variable is a list of directory paths where Python searches for modules, so type(sys.path) is list evaluates to True. Therefore b1 and b2 are both True, and True and True evaluates to True.

Why the other options are wrong

  • A. None is not the output; the expression evaluates to a boolean value.
  • C. The integer 0 is not returned; boolean True is the result.
  • D. Both conditions are True, so the and operation returns True, not False.

Question 3

A Python package named pypack includes a module named pymod.py which contains a function named pyfun().

Which of the following snippets will let you invoke the function? (Choose two.)

  1. from pypack.pymod import pyfun pyfun()
  2. import pypack pymod.pyfun()
  3. from pypack import * pyfun()
  4. import pypack import pypack.pymod pypack.pymod.pyfun()
Show answer and explanation

Correct answer: A, D

A. from pypack.pymod import pyfun pyfun() D. import pypack import pypack.pymod pypack.pymod.pyfun() Option A is correct: 'from pypack.pymod import pyfun' directly imports the function, allowing it to be called as pyfun(). Option D is correct: importing pypack and then pypack.pymod allows calling the function via the full path pypack.pymod.pyfun(). Option B is incorrect because importing pypack doesn't automatically import its submodules; pymod would be undefined. Option C is incorrect because 'from pypack import *' only works if __init__.py explicitly defines __all__ or imports pyfun; otherwise pyfun remains inaccessible.

Why the other options are wrong

  • B. Importing pypack does not automatically import submodules; pymod is not defined in the namespace.
  • C. The 'from pypack import *' statement only imports names defined in pypack's __init__.py or its __all__ list, and pyfun is in a submodule.

See all 10 free questions Get the full pack, US$39

129 practice questions for Python Institute Certified Associate in Python Programming (PCAP-31-03), MCQs and fill-in-the-blank, with full explanations.

Every question comes with the correct answer, a clear explanation, and a note on why each other option is wrong, including every fill-in-the-blank format from the objectives so nothing about it is new on exam day.

  • 129 questions, MCQs and fill-in-the-blank, mapped to the PCAP-31-03 exam objectives
  • Answers and explanations for every question, including the wrong options
  • A questions-only PDF for timed practice runs
  • Instant delivery by email the moment you check out
  • Free monthly updates for as long as the exam is live
  • Pass or your money back

A failed PCAP attempt costs another US$295, plus the time it takes to prepare again. This pack is US$39, paid once, and refunded if you fail.

Try 10 questions free before you buy.

Last updated September 2026 · 129 questions

What makes the PCAP hard

The PCAP is a significant step up from the PCEP. The questions go deeper into OOP, modules, exceptions and file handling, and the fill-in-the-blank format means you cannot guess: you have to know the syntax exactly. At US$295 a sitting, walking in underprepared is an expensive mistake.

Only 40 questions in 65 minutes, and 70% to pass, so 12 wrong answers ends it. With object-oriented programming worth roughly a third of the paper, a weak spot there is usually the whole exam.

About the exam

The PCAP is Python Institute’s intermediate-level certification. It validates the ability to design, develop, debug and refactor multi-module Python programs with a strong focus on object-oriented programming. It is the next step after the PCEP and a prerequisite for the PCPP professional certifications, delivered through Pearson VUE at testing centres or online.

Exam domains

  • Modules and packages
  • Exceptions
  • Strings
  • Object-oriented programming
  • Miscellaneous: list comprehensions, lambdas, closures and file I/O

40 questions, 65 minutes (plus 10 minutes for the NDA and tutorial), passing score 70%, taken at Pearson VUE testing centres or online, includes fill-in-the-blank questions, from US$295 per attempt.

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Questions before you buy

What do I get when I buy the Python Institute PCAP-31-03 pack?

129 practice questions as a PDF, each with the correct answer, a full explanation and a note on why the other options are wrong, plus a separate questions-only PDF for timed practice.

How quickly do I receive it?

Straight away. The full PDF and a questions-only copy are emailed to you the moment your payment goes through, and the same links are on your order page.

Is there a free sample?

Yes. Ten questions from this pack, with answers and explanations, are free on this page and as a PDF, so you can judge the quality before you pay.

Are updates included?

Yes. The pack is updated every month for as long as the exam is live, and updates are free for everyone who has bought it.

What if I fail the exam?

We refund the pack. Sit the exam 7 to 30 days after buying, then send your official score report within 7 days of the exam date, as set out in the refund policy.

Can I share it with colleagues?

Each purchase is licensed to one person. For a team, school or training organisation, email support@certstash.com for a licence that fits.