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

Python Institute PCEP-30-02 PCEP - Certified Entry-Level Python Programmer Exam Practice Test

Page: 1 / 4
Total 42 questions

PCEP - Certified Entry-Level Python Programmer Questions and Answers

Question 1

Drag and drop the literals to match their data type names.

Question # 1

Options:

Question 2

Insert the code boxes in the correct positions in order to build a line of code which asks the user for an Integer value and assigns it to the depth variable.

(Note: some code boxes will not be used.)

Question # 2

Options:

Question 3

Insert the code boxes in the correct positions in order to build a line of code which asks the user for an integer value and assigns it to the depth variable.

(Note: some code boxes will not be used.)

Question # 3

Options:

Question 4

Python Is an example of which programming language category?

Options:

A.

interpreted

B.

assembly

C.

compiled

D.

machine

Question 5

Assuming that the phonc_dir dictionary contains namemumber pairs, arrange the code boxes to create a valid line of code which retrieves Martin Eden's phone number, and assigns it to the number variable.

Question # 5

Options:

Question 6

Drag and drop the literals to match their data type names.

Question # 6

Options:

Question 7

What is the expected output of the following code?

Question # 7

Options:

A.

1

B.

The code raises an unhandled exception.

C.

False

D.

('Fermi ', '2021', 'False')

Question 8

What is true about exceptions in Python? (Select two answers.)

Options:

A.

According 10 Python terminology, exceptions are thrown

B.

According to Python terminology, exceptions are raised

C.

Python's philosophy encourages developers to make all possible efforts to protect the program from the occurrence of an exception.

D.

Not more than one except branch can be executed inside one try-except block.

Question 9

A program written in a high-level programming language is called:

Options:

A.

a binary code

B.

machine code

C.

the ASCI I code

D.

a source code

Question 10

What is the expected result of running the following code?

Question # 10

Options:

A.

The code prints 1 .

B.

The code prints 2

C.

The code raises an unhandled exception.

D.

The code prints 0

Question 11

Arrange the code boxes in the correct positions in order to obtain a loop which executes its body with the counter variable going through values 1, 3 , and 5 (in the same order)

Question # 11

Options:

Question 12

What is true about exceptions and debugging? (Select two answers.)

Options:

A.

A tool that allows you to precisely trace program execution is called a debugger.

B.

If some Python code is executed without errors, this proves that there are no errors in it.

C.

One try-except block may contain more than one except branch.

D.

The default (anonymous) except branch cannot be the last branch in the try-except block.

Page: 1 / 4
Total 42 questions