
Python InstitutePCAP - Certified Associate Python Programmer
Domain 1Objective 1
PCAP-31-03 1.1 Import and Use Modules and Packages PCAP-31 Practice Questions (Page 3)
Part of the Modules and Packages domain, which accounts for 12% of the PCAP-31 exam. Python Institute does not publish an official question count, but from its 65-minute exam (~25–45 total, ~3–5 in this domain), expect 1–1 from this objective — we provide 19 practice questions to prepare you well beyond it. (estimate)
19questions here
4free pages
8concepts
12%of the exam
Questions 11–15
- 11
After `import math`, which call lists the names defined in the `math` module?
Select an answer first - 12
After executing `import os.path`, which expression correctly refers to the `join` function?
Select an answer first - 13
Given a package `pkg` with a submodule `sub`, which statement imports `sub` so that you can access its function `func` as `pkg.sub.func()`?
Select an answer first - 14
A company has a package structure `company/utils/helpers.py`. A developer needs to use the `format_date` function defined in `helpers.py` from a script located in a different directory. The `company` package is installed and accessible via `sys.path`. Which import statement correctly imports the function and allows calling it as `format_date()`?
Select an answer first - 15
A developer has imported several modules and defined several functions in a script. The developer wants to see a list of all names currently defined in the global scope of the script. Which code snippet will achieve 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.