Summer Sale - Limited Time 65% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: 65percent

Welcome To DumpsPedia

PCPP-32-101 Sample Questions Answers

Questions 4

What is true about the unbind () method? (Select two answers.)

Options:

A.

It is invoked from within the events object

B.

It is invoked from within a widget's object

C.

It needs a widget's object as an argument

D.

It needs the event name as an argument

Buy Now
Questions 5

What is wrong with the following snippet?

class A:

def run(self):

print("A is running")

class B(A):

def run(self):

print("B is running")

class C(A, B):

def fly(self):

print("C is flying")

c = C()

Options:

A.

There is no run() method defined for the C class.

B.

It causes MRO inconsistency.

C.

Nothing. The code is fine.

D.

There are no __init__() methods — each class should implement this method.

Buy Now
Questions 6

What is true about the following snippet of code?

class Cat:

def __init__(self, weight, sex):

self.height = height

self.weight = weight

self.sex = sex

def say(self):

print('meows')

kitty = Cat(1, 'male')

kitty.say()

Options:

A.

The snippet will print: 1 male.

B.

The snippet will cause a NameError exception.

C.

The snippet will print: meows.

D.

The snippet will cause a ValueError exception.

Buy Now
Questions 7

Select the true statement related to PEP 257.

Options:

A.

String literals that occur immediately after another docstring are called attribute docstrings.

B.

Attribute docstrings and Additional docstrings are two types of extra docstrings that can be extracted by software tools.

C.

String Iiterals that occur in places other than the first statement in a module, function, or class definition can act as documentation They are recognized by the Python bytecode compiler and are accessible as runtime object attributes

D.

String literals that occur immediately after a simple assignment at the top level of a module are called complementary docstrings

Buy Now
Questions 8

Analyze the following snippet and select the statement that best describes it.

Options:

A.

The code is syntactically correct despite the fact that the names of the function parameters do not follow the naming convention

B.

The *arg parameter holds a list of unnamed parameters

C.

The code is missing a placeholder for unnamed parameters.

D.

The code is syntactically incorrect - the function should be defined as def f1 (*args, **kwargs) :

Buy Now
Questions 9

What will be the content of the cars.xml file when you run the following code?

import xml.etree.ElementTree as ET

root = ET.Element('data')

car_1 = ET.SubElement(root, 'car', {'brand': 'Audi'})

car_2 = ET.SubElement(root, 'car', {'brand': 'Volkswagen'})

tree = ET.ElementTree(root)

tree.write('cars.xml', 'UTF-8', True)

Options:

A.

< data > < car brand="Audi" / > < car brand="Volkswagen" / > < /data >

B.

< ?xml version='1.0'? >

< data > < car brand="Audi" / > < car brand="Volkswagen" / > < /data >

C.

< ?xml version='1.0' encoding='UTF-8'? >

< data > < car brand="Audi" / > < car brand="Volkswagen" / > < /data >

D.

< ?xml? >

< data > < car brand="Audi" / > < car brand="Volkswagen" / > < /data >

Buy Now
Questions 10

Analyze the following snippet and choose the best statement that describes it.

class Sword:

var1 = 'weapon'

def __init__(self):

self.name = 'Excalibur'

s1 = Sword()

Options:

A.

The snippet will cause an AttributeError exception.

B.

The snippet will cause a ValueError exception.

C.

The class variable value can be updated with the following code: cls.var1

D.

The class variable value can be updated with the following code: Sword.var1

Buy Now
Questions 11

Select the true statements about the following invocation:

(Select two answers.)

Options:

A.

It addresses a service deployed at localhost (the host where the code is run).

B.

It addresses a service whose timeout is set to 3000 ms.

C.

It addresses a service located at the following address local.host.com.

D.

It addresses a service listening at port 3000.

Buy Now
Questions 12

Select the true statements about the connection-oriented and connectionless types of communication. (Select two answers.)

Options:

A.

In the context of TCP/IP networks, the communication side that initiates a connection is called the client, whereas the side that answers the client is called the server

B.

Connectionless communications are usually built on top of TCP

C.

Using walkie-talkies is an example of a connection-oriented communication

D.

A phone call is an example of a connection-oriented communication

Buy Now
Questions 13

Which of the following values can be returned by the messagebox. askquestion () method?

Options:

A.

"accept:" and "cancel''

B.

l and o

C.

"yes" and "no"

D.

True and False

Buy Now
Questions 14

Which of the following methods allow you to load a configuration using ConfigParser? (Select two answers.)

Options:

A.

read

B.

read_dict

C.

read_conf

D.

read_str

Buy Now
Questions 15

Which of the following constants will be used if you do riot define the quoting argument in the writer method provided by the csv module?

Options:

A.

csv.QUOTE_MINIMAL

B.

csv.QUOTE_NONE

C.

svQUOTE_ALL

D.

csv.QUOTE_NONNUMERIC

Buy Now
Questions 16

What will happen if the mam window is too small to fit all its widgets?

Options:

A.

Some widgets may be invisible

B.

The window will be expanded.

C.

An exception will be raised.

D.

The widgets will be scaled down to fit the window's size.

Buy Now
Questions 17

Which of the following types cannot be pickled?

Options:

A.

integers, floating-point numbers, complex numbers

B.

function and class definitions

C.

None, booleans

D.

strings, bytes, bytearrays

Buy Now
Questions 18

Which of the following statements related to :memory: are true?

(Select two answers.)

Options:

A.

:memory: is a special name for loading a database from a file to the RAM.

B.

You can use :memory: to delete a specific database that resides in the RAM.

C.

You can use :memory: to establish a database connection.

D.

:memory: is a special name for creating a temporary database in the RAM.

Buy Now
Questions 19

The following snippet represents one of the OOP pillars Which one is that?

Options:

A.

Serialization

B.

Inheritance

C.

Encapsulation

D.

Polymorphism

Buy Now
Questions 20

Select the true statements about the json.loads() function.

(Select two answers.)

Options:

A.

It takes Python data as its argument.

B.

It returns a JSON string.

C.

It takes a JSON string as its argument.

D.

It returns a Python entity.

Buy Now
Exam Code: PCPP-32-101
Exam Name: PCPP1 – Certified Professional in Python Programming 1
Last Update: Jul 15, 2026
Questions: 69

PDF + Testing Engine

$59.99 $171.4

Testing Engine

$44.99 $128.55

PDF (Q&A)

$49.99 $142.82