Certified Associate in Python Programming Questions and Answers
How many elements will the list1 list contain after execution of the following snippet?
What will the value of the i variable be when the following loop finishes its execution?

Which of the following literals reflect the value given as 34.23? (select two answers)
The__bases__property contains:
What is the expected behavior of the following code?

A class constructor (Select two answers)
What is the expected output of the following code?

Assuming that the snippet below has been executed successfully, which of the following expressions will evaluate to True? (Select two answers)
string = 'SKY' (:: -1)
string = string (-1)
Which line can be used instead of the comment to cause the snippet to produce the following expected output? (Select two answers)
Expected output:
1 2 3
Code:

What is the expected behavior of the following code?

What is the expected behavior of the following code?

Assuming that the following inheritance set is in force, which of the following classes are declared properly? (Select two answers)

Assuming that the following code has been executed successfully, selected the expression which evaluate to True (Select two answers)

What is the expected behavior of the following code?

You are going to read 16 bytes from a binary file into a bytearray called data. Which lines would you use? (Select two answers)
Which of the following statements are true? {Select two answers)
What is the expected behavior of the following snippet?

It will:
The following expression
1+-2
is:
A Python module named pymod.py contains a variable named pyvar.
Which of the following snippets will let you access the variable? (Select two answers)
Assuming that the code below has been executed successfully, which of the following expressions will always evaluate to True? (Select two answers)
import random
v1 = random. random()
v2 = random. random()
What is the expected output of the following snippet?

A Python module named pymod, py contains a function named pyfun ( ).
Which of the following snippets will let you invoke the function? (Select two answers)
Which of the following expressions evaluate to True? (Select two answers)
What is the expected behavior of the following code?

It will
Which of the following expressions evaluate to True? (Select two answers)
Which of the following invocations are valid? (Select two answers)
There is a stream named s open for writing. What option will you select to write a line to the stream''
A method for passing the arguments used by the following snippet is called:

The following class hierarchy is given. What is the expected out of the code?

What is the expected behavior of the following code?

It will:
Which of the following lines of code will work flawlessly when put independently inside the add_new () method in order to make the snippet's output equal to [0, 1, 21 ? (Select two answers)

Which of the following statements are true? (Select two answers)
What is the expected output of the following code?

What is the expected behavior of the following code?

With regards to the directory structure below, select the proper forms of the directives in order to import module_c. (Select two answers)

What is the expected behavior of the following code?

What is the expected behavior of the following code?

Assuming that the code below has been placed inside a file named code.py and executed successfully, which of the following expressions evaluate to True? (Select two answers)

A compiler is a program designed to (select two answers)
How many elements will the list2 list contain after execution of the following snippet?
list1 = [False for i in range (1, 10) ]
list2 = list1 [-1:1:-1]
What is the expected behavior of the following code?

An operator able to perform bitwise shifts is coded as (select two answers)
How many lines does the following snippet output?

What can you do if you don't like a long package path tike this one0 import alpha.beta.gamma.delta.epsiIon.zeta
What will be the value of the i variable when the while e loop finishes its execution?

What is true about the following snippet? (Select two answers)
