Win IT Exam with Last Dumps 2024


Python PCAP Exam

Page 13/15
Viewing Questions 121 130 out of 146 Questions
86.67%

Question 121
The __bases__ property contains:
A. base class location (addr)
B. base class objects (class)
C. base class names (str)
D. base class ids (int)

Question 122
What is the expected behavior of the following code?
Image PCAP_122Q.png related to the Python PCAP Exam
A. it outputs 0
B. it raises an exception
C. it outputs 1
D. it outputs 2

Question 123
Which of the following statements are true? (Choose two.)
A. an escape sequence can be recognized by the / sign put in front of it
B. II in ASCII stands for Internal Information
C. ASCII is a subset of UNICODE
D. a code point is a number assigned to a given character

Question 124
What is the expected behavior of the following code?
Image PCAP_124Q.png related to the Python PCAP Exam
A. it outputs 321
B. it outputs 123
C. it outputs 6
D. it raises an exception

Question 125
A Python module named pymod.
py contains a variable named pyvar.
Which of the following snippets will let you access the variable? (Choose two.)
A. import pymod pymod.pyvar = 1
B. import pyvar from pymod pyvar = 1
C. from pymod import pyvar pyvar ()
D. from pyfun import * pyvar = 1


Question 126
Which of the following expressions evaluate to True? (Choose two.)
A. ord("z")-ord("Z")==ord("0")
B. len("""""")>0
C. chr(ord('a')+1)=='B'
D. len('\'')==1

Question 127
What is the expected output of the following code if the file named non_zero_length_existing_text_file is a non-zero length file located inside the working directory?
Image PCAP_127Q.png related to the Python PCAP Exam
A. -1
B. 0
C. an errno value corresponding to file not found
D. 1

Question 128
Assuming that the code below has been executed successfully, which of the expressions evaluate to True? (Choose two.)
Image PCAP_128Q.png related to the Python PCAP Exam
A. 'var' in Class.__dict__
B. 'var' in Object.__dict__
C. len(Object.__dict__) == 1
D. 'prop' in Class.__dict__

Question 129
What is the expected behavior of the following code?
Image PCAP_129Q.png related to the Python PCAP Exam
A. it raises an exception
B. it outputs nothing
C. it outputs True
D. it outputs False

Question 130
Assuming that the code below has been executed successfully, which of the following expressions will always evaluate to True? (Choose two.)
Image PCAP_130Q.png related to the Python PCAP Exam
A. v1 == v2
B. v1 < 1
C. random.choice([1,2,3])>0
D. len(random.sample([1,2,3],1))>2