Certified Professional in Python Programming 1

Here you have the best Python Institute PCPP-32-101 practice exam questions

  • You have 80 total questions across 16 pages (5 per page)
  • These questions were last updated on February 20, 2026
  • This site is not affiliated with or endorsed by Python Institute.
Question 1 of 80

Select the true statement about composition.
Answer

Suggested Answer

The suggested answer is B.

Composition allows a class to be projected as a container of different classes. This is because composition involves building complex types by combining objects of other types, establishing a 'has-a' relationship. It promotes flexibility and modular code design since the container class can access the public interface of the contained classes, but not their internal details.

Community Votes2 votes
BSuggested
100%
Question 2 of 80

Analyze the following snippet and select the statement that best describes it.
Exam PCPP-32-101: Question 2 - Image 1
Answer

Suggested Answer

The suggested answer is B.

The code is erroneous because the OwnMath class does not inherit from any Exception type class. In Python, exceptions must be derived from BaseException or its subclasses. Attempting to use a class that does not inherit from an exception base class as an exception will result in a TypeError. Therefore, the provided class definition for OwnMath is incorrect for exception handling purposes.

Community Votes8 votes
BSuggested
88%
A
13%
Question 3 of 80

Analyze the following snippet and select the statement that best describes it.
Exam PCPP-32-101: Question 3 - Image 1
Answer

Suggested Answer

The suggested answer is C.

The given code snippet defines a class named Sword. Within this class, 'var1' is set as a class variable with the value 'weapon'. The initializer method '__init__' defines 'self.name' as an instance variable and assigns it the value 'Excalibur'. So, 'Excalibur' is the value assigned to an instance variable when an object of the class Sword is created.

Community Votes4 votes
CSuggested
100%
Question 4 of 80

The following snippet represents one of the OOP pillars. Which one is that?
Exam PCPP-32-101: Question 4 - Image 1
Answer

Suggested Answer

The suggested answer is D.

The snippet shows different classes where some have a method named 'run'. Despite the presence of the 'fly' method in class B, the attempt to execute 'run' on all instances showcases the concept of polymorphism. Polymorphism allows objects of different classes to be treated as objects of a common superclass. It facilitates the execution of the same method (or interface) in different ways for various object instances. In this example, the intention is to invoke the 'run' method polymorphically, although it would encounter an error due to the 'fly' method in class B.

Community Votes3 votes
DSuggested
100%
Question 5 of 80

Analyze the following function and choose the statement that best describes it.
Exam PCPP-32-101: Question 5 - Image 1
Answer

Suggested Answer

The suggested answer is D.

The function presented is erroneous. The code references a variable 'our_function' which is not defined anywhere within the scope of the function. Additionally, there is a missing colon in line 3. These issues would result in a NameError when the code is executed, thus making the function incorrect as written. To correct this, ensuring that the referenced function names are consistent and properly defined is necessary.

Community Votes6 votes
DSuggested
100%

About the Python Institute PCPP-32-101 Certification Exam

About the Exam

The Python Institute PCPP-32-101 (Certified Professional in Python Programming 1) validates your knowledge and skills. Passing demonstrates proficiency and can boost your career prospects in the field.

How to Prepare

Work through all 80 practice questions across 16 pages. Focus on understanding the reasoning behind each answer rather than memorizing responses to be ready for any variation on the real exam.

Why Practice Exams?

Practice exams help you familiarize yourself with the question format, manage your time, and reduce anxiety on the test day. Our PCPP-32-101 questions are regularly updated to reflect the latest exam objectives.