Ticking Clock Black Friday Special: 75% Off! Apply coupon code below to save on all exam bundles! - Ends in 0d 00h 00m 00s - Coupon code: estly75

Which of the following expression evaluate to True? (Select two answers)

A)

question 21

B)

question 21

C)

question 21

D)

question 21

A.

Option A

B.

Option B

C.

Option C

D.

Option D

Which of the following statement are true? (Select two answers)

A.

closing an open file is performed by the closefile ( ) function

B.

the second open ( ) argument describes the open mode and defaults to ‘w’

C.

if open ( ) ‘s second argument is ‘r’ the file must exist or open will fail

D.

if open ( )’s second argument is ‘w’ and the invocation succeeds, the previous file’s content is lost

Which one of the platform module functions should be used to determine the underlying platform name?

A.

platform.uname ()

B.

platform.platform ()

C.

platform.python_version()

D.

platform.processor()

What is the expected behavior of the following code?

question 24

It will

A.

print 2 1

B.

print 1 2

C.

cause a runtime exception

D.

print

What is the expected output of the following snippet?

question 25

A.

True lower

B.

True upper

C.

False upper

D.

False lower

What is the output of the following piece of code?

question 26

A.

ant'bat'camel

B.

ant"bat"camel

C.

antbatcamel

D.

ant bat camel

What is the expected behavior of the following code?

x = 8 ** (1/3)

y = 2. if x < 2.3 else 3.

print(y)

A.

it outputs 2.0

B.

it outputs 2. 5

C.

the code is erroneus and it will not execute

D.

it outputs 3.0

What is the expected behavior of the following code?

question 28

A.

It outputs False

B.

It outputs nothing

C.

It outputs True

D.

It raises an exception

What is the expected behavior of the following code?

question 29

A.

it outputs 0

B.

it outputs 1

C.

it raises an exception

D.

it outputs 2

What is true about the __based__attribute in Python?

A.

It is accessible inside a class and an object.

B.

There is no such property.

C.

it is accessible inside an object

D.

It is accessible inside a class