Python Institute certification · Exam PCAP-31-03

PCAP-31-03 Mock Exam Page 2

Certified Associate in Python Programming

Free PCAP-31-03 mock exam questions 11–20, each with the answer and an explanation.

20 questions · 33 minutes · free, no sign-up

Free PCAP-31-03 questions

11–20 of 39 free
Question 11 Choose 1
How many elements will the list1 list contain after execution of the following snippet?
Show answerHide answer

Correct answer: A two

Question 12 Choose 2
Which of the following sentences are true? (Select two answers)
Show answerHide answer

Correct answer: B, D tuples may be stored inside listslists may be stored inside lists

Question 13 Choose 1
What is the expected behavior of the following code?

Show answerHide answer

Correct answer: D it outputs 6

Question 14 Choose 2
With regards to the directory structure below, select the proper forms of the directives in order to import module_a. (Select two answers)

Show answerHide answer

Correct answer: A, D import pypack.module_afrom pypack import module_a

Question 15 Choose 2
Which of the following statements are true? (Select two answers)
Show answerHide answer

Correct answer: B, C Python strings can be concatenatedPython strings can be sliced like lists

Question 16 Choose 1
The following class hierarchy is given. What is the expected out of the code?

Show answerHide answer

Correct answer: D BC

Question 17 Choose 2
Which of the following invocations are valid? (Select two answers)
Show answerHide answer

Correct answer: B, D sorted("python")"python".index("th")

Question 18 Choose 2
Which of the listed actions can be applied to the following tuple? (Select two answers)
Show answerHide answer

Correct answer: A, D tup [:]del tup

Question 19 Choose 1
What is the expected behavior of the following code?

Show answerHide answer

Correct answer: A it outputs -2

Question 20 Choose 2
What is true about Object-Oriented Programming in Python? (Select two answers)
Show answerHide answer

Correct answer: A, C encapsulation allows you to protect some data from uncontrolled accessinheritance is the relation between a superclass and a subclass

Full mock exam

Sit the PCAP-31-03 exam before exam day

Full-length mocks with the same number of questions and the same time limit as the real PCAP-31-03 exam. Every attempt draws a new set of questions from the full bank, so you can keep going until you pass comfortably.

Get full PCAP-31-03 mock exam
  • 65questions per mock
  • 105 mintime limit
  • 133questions in the bank
  • Newmock on every attempt