Why Study with PlanetCert?
The Latest Questions
Practice questions and exam topics aligned with the current exam objectives.
Detailed Explanations
Go beyond the answer. Master the material with comprehensive learning and professional explanations for every concept.

AI-Powered Insights
Personalized preparation guidance that adapts to your performance and identifies weak spots automatically.
Exam Information
Official specifications published by Python Institute
Exam Format
Registration
Validity
Skills this practice test covers
- Import modules with import, from import and import as, and inspect them with dir() and sys.path.
- Use the math, random and platform modules, for example ceil(), seed() and python_version_tuple().
- Handle errors with except branches, raise and assert, and define custom exception classes.
- Work with characters as code points through ord() and chr(), and with strings through slicing and methods.
- Build classes with single and multiple inheritance, and inspect them with isinstance() and __dict__.
- Write list comprehensions, lambdas with map() and filter(), closures, and file reads and writes.
Explore related topics
PCAP exam content
5 domains · 21 topics · 236 of 316 questions sorted by domain
Modules and Packages12%49 questions
This domain covers how Python finds and loads code. Candidates import modules in several forms, use the math, random and platform modules, and build packages of their own.
Skills tested
- Use import, import as, from import and import *, and qualify names in nested modules.
- Inspect a module with the dir() function and the sys.path variable.
- Calculate with ceil(), floor(), trunc(), factorial(), hypot() and sqrt() from math.
- Generate values with random(), seed(), choice() and sample().
- Build a package with an __init__.py file, and explain the __pycache__ directory and __name__.
Questions by topic
- Create and use user-defined modules and packages9
- Discover host platform properties using the platform module10
- Import and use modules and packages11
- Generate random values using the random module9
- Perform evaluations using the math module10
Exceptions14%30 questions
A program must deal with errors instead of crashing. This domain covers except branches, the hierarchy of exceptions, raise and assert, and exception classes a programmer defines.
Skills tested
- Order except branches correctly, including except (e1, e2), except E as e and the else branch.
- Raise exceptions with raise and raise ex, and check conditions with assert.
- Use the hierarchy of exceptions to predict which branch catches an error.
- Create self-defined exceptions by subclassing an existing exception class.
Questions by topic
- Handle errors using Python-defined exceptions19
- Extend the Python exceptions hierarchy with self-defined exceptions11
Strings18%39 questions
Python stores text as a sequence of Unicode code points. This domain covers character encoding, operations on strings and the built-in string methods.
Skills tested
- Convert between characters and code points with ord() and chr(), and read escape sequences.
- Index, slice, iterate through, concatenate, multiply and compare strings.
- Explain why strings are immutable and what that means for string methods.
- Use .split(), .join(), .find(), .rfind(), .index(), sorted() and the .isxxx() methods.
Questions by topic
- Operate on strings15
- Understand machine representation of characters9
- Employ built-in string methods15
Object-Oriented Programming34%72 questions
The largest domain is about classes and objects. Candidates declare classes with variables and methods, build hierarchies with inheritance, and inspect classes and objects while the program runs.
Skills tested
- Declare class and instance variables and read them through the __dict__ property.
- Make components private and explain name mangling.
- Write methods with the self parameter and constructors with __init__.
- Build single and multiple inheritance, including diamonds, and override methods.
- Inspect classes with hasattr(), isinstance(), __name__, __module__ and __bases__.
Questions by topic
- Build a class hierarchy using inheritance19
- Employ class and object properties11
- Equip a class with methods11
- Discover the class structure12
- Understand the Object-Oriented approach8
- Construct and initialize objects9
- Create and use user-defined modules and packages2
Miscellaneous22%46 questions
This domain gathers list comprehensions, lambda functions, closures and file input and output. Each topic is small, but together they form the second-largest domain.
Skills tested
- Write list comprehensions with an if condition, including nested comprehensions.
- Pass lambdas to map() and filter().
- Define a closure and explain why it keeps its variables.
- Open files in text or binary mode, read them with read(), readline() and readlines(), and check errno.
Questions by topic
- Build complex lists using list comprehension15
- Define and use closures11
- Perform Input/Output operations12
- Embed lambda functions into the code8
Requirements
- No formal prerequisites: anyone can book the exam.
- Recommended: PCEP or the same entry-level Python knowledge.
- Recommended: at least six months of Python programming, including some object-oriented code.
- Recommended: familiarity with the Python standard library.
About the PCAP exam
PCAP is Python Institute's associate-level exam for programmers who write intermediate Python: classes, modules, exceptions and string handling. It sits one level above the entry-level PCEP exam. Object-Oriented Programming is the largest of its five domains. Passing earns the PCAP – Certified Associate Python Programmer certification, which does not expire.
The PlanetCert practice test follows the same five domains, with the most questions on Object-Oriented Programming. The explanations help with details that are easy to misread, such as name mangling of private variables or which except branch catches an error. Study Mode suits the Miscellaneous domain, where closures and lambdas reward slow reading. Brainy AI Assistant can explain why a snippet prints what it does, or generate another question on a tricky inheritance case.
How to earn the certification
- Earns
- PCAP – Certified Associate Python ProgrammerAssociate
The PCAP certification has lifetime validity and does not need renewal.
- Before
- PCEP-30-02 PCEP – Certified Entry-Level Python Programmer
Python Institute's entry-level exam. Python Institute recommends it, or the same knowledge, before PCAP.
- PCEP-30-02 PCEP – Certified Entry-Level Python Programmer
- After
- PCPP-32-101 PCPP1 – Certified Professional Python Programmer Level 1
The professional-level exam that comes after PCAP in the Python Institute track.
- PCPP-32-101 PCPP1 – Certified Professional Python Programmer Level 1
How to prepare for PCAP
- 1
Test every snippet in Python 3
Run each syllabus example in a Python 3 interpreter instead of guessing its output. Details such as the order of except branches are easiest to learn from the real error message.
- 2
Build one package from scratch
Create a package with an __init__.py file and a nested module, import it in each form, and print __name__ and sys.path. This covers much of the Modules and Packages domain.
- 3
Draw class hierarchies on paper
Object-Oriented Programming is the largest domain. Sketch the classes before predicting what code with multiple inheritance or overridden methods will print.
- 4
Rewrite loops three ways
Turn a short loop into a list comprehension, then into map() and filter() with a lambda. Finish with a closure that counts its own calls, to see why it keeps its variable.
- 5
Time a full PCAP practice run
Take the PCAP practice test in timed mode and read the explanation for every miss. Ask Brainy AI Assistant to trace any snippet whose output came as a surprise.
Start a timed PCAPrun
Who PCAP is for
- Python programmers who know the basics and are moving to object-oriented code.
- Holders of PCEP who want the next Python Institute certification.
- Students and junior developers who want proof of intermediate Python skills.
Typical job titles: Python developer · Junior software developer · Software engineer · Automation developer
PCAP glossary
17 terms from the exam objectives and the vendor's official material, each defined in a sentence.
- __init__.py file
- A file that marks a directory as a Python package; its code runs when the package is first imported.
- __name__ variable
- A module's name; it holds the value __main__ when the file runs as a script instead of being imported.
- __pycache__ directory
- The folder where Python stores compiled versions of imported modules, so that they load faster next time.
- bytearray
- A changeable sequence of bytes, often used as a buffer when reading binary data from a file.
- Closures
- Functions that keep access to variables from the scope where they were created, even after that scope has ended.
- Code points
- The numbers that Unicode gives to characters; ord() returns a character's code point and chr() turns it back.
- Diamonds
- A multiple inheritance shape in which a class inherits from two classes that share the same superclass.
- errno variable
- The error code that an input or output exception carries, which tells the program why an operation such as open() failed.
- hasattr() function
- A built-in function that checks whether an object or a class has an attribute with a given name.
- Immutability
- The rule that a string cannot be changed in place, so every string method returns a new string.
- isinstance() function
- A built-in function that checks whether an object belongs to a class or to one of its subclasses.
- Lambda functions
- Small anonymous functions written as one expression, often passed to map() or filter().
- List comprehension
- A short expression that builds a new list from an iterable, optionally filtered with an if condition.
- Name mangling
- Python's renaming of attributes whose names start with two underscores, which makes them hard to reach from outside the class.
- Polymorphism
- Calling the same method on objects of different classes, with each class supplying its own behavior.
- Self-defined exceptions
- Exception classes that a programmer creates by subclassing an existing exception, to signal errors specific to a program.
- sys.path variable
- The list of directories that Python searches, in order, when it imports a module.
Related practice tests
- PCEP-30-02Pcep – Certified Entry-Level Python Programmer
- PCES-30-01PCES – Certified Entry-Level Security Specialist with Python
- PCET-30-01PCET™ – Certified Entry-Level Tester with Python
- PCPP-32-101PCPP1 – Certified Professional Python Programmer Level 1