Certbus > Python Institute > Python Institute Certifications > PCEP-30-02 > PCEP-30-02 Online Practice Questions and Answers

PCEP-30-02 Online Practice Questions and Answers

Questions 4

What is the expected output of the following code?

A. 8

B. 7.0

C. 8.0

D. 9.0

Browse 420 Q&As
Questions 5

What would you insert instead of ???, so that the program prints True to the monitor?

A. x < y

B. x is not y

C. x is y

D. x != y

Browse 420 Q&As
Questions 6

What is the output of the following snippet?

A. 25.0

B. The snippet will cause an execution error.

C. 17.0

D. 17

Browse 420 Q&As
Questions 7

What is the expected output of the following code?

A. 1 | False 2 | True 3 | False 4 | True

B. 1 | False 2 | True 3 | True 4 | True

C. 1 | False 2 | True 3 | True 4 | False

D. 1 | False 2 | False 3 | True 4 | True

Browse 420 Q&As
Questions 8

What is the expected output of the following code?

A. 0 1

B. 1 0

C. The code is erroneous.

D. 0 0

E. 1 1

Browse 420 Q&As
Questions 9

What do you call a tool that lets you launch your code step-by-step and inspect it at each moment of execution?

A. An editor

B. A debugger

C. A console

Browse 420 Q&As
Questions 10

Which one of the following is an example of a Python le extension?

A. pi

B. py

C. p

Browse 420 Q&As
Questions 11

Which of the following enclose the input parameters or arguments of a function?

A. Brackets

B. Quotation marks

C. Curly braces

D. Parentheses

Browse 420 Q&As
Questions 12

What is the expected output of the following code?

A. 1

B. Peter

C. None

D. value

E. The code is erroneous.

Browse 420 Q&As
Questions 13

What is the expected output of the following code?

A. acdef

B. The code is erroneous.

C. abdef

D. abcef

Browse 420 Q&As
Questions 14

What is the expected output of the following code?

A. 2

B. The code is erroneous.

C. 0

D. 1

Browse 420 Q&As
Questions 15

What is the expected behavior of the following program?

A. The program will cause a ValueError exception and output a default error message.

B. The program will cause a SyntaxError exception.

C. The program will cause a ZeroDivisionError exception and output a default error message.

D. The program will cause a ValueError exception and output the following message: Too bad...

E. The program will raise an exception handled by the rst except block.

Browse 420 Q&As
Questions 16

The part of your code where you think an exception may occur should be placed inside:

A. the except: branch

B. the exception: branch

C. the try: branch

Browse 420 Q&As
Questions 17

How many stars (*) will the following code output to the screen?

A. one

B. six

C. two

D. three

Browse 420 Q&As
Questions 18

What is the expected output of the following code? print(len([i for i in range(0, -2)]))

A. 1

B. 3

C. 2

D. 0

Browse 420 Q&As
Exam Code: PCEP-30-02
Exam Name: PCEP - Certified Entry-Level Python Programmer
Last Update: Mar 15, 2025
Questions: 420 Q&As

PDF

$49.99

VCE

$55.99

PDF + VCE

$65.99