Free PCEP-30-02 Exam Braindumps (page: 8)

Page 7 of 99

What is the expected output of the following code?

  1. False
  2. 1
  3. 0
  4. True

Answer(s): A



Which one of the lines should you put in the snippet below to match the expected output?
Expected output:

Code:

  1. reverse(list)
  2. list.reversed()
  3. list.reverse()
  4. reversed(list)

Answer(s): C



What is the expected output of the following code?

  1. ['1', '2', '3', '4']
  2. (1, 2, 3, 4)
  3. ('1', '2', '3', '4')
  4. The code is erroneous.

Answer(s): C



What is the expected output of the following code?

  1. (2)
  2. (2,)
  3. 2
  4. The code is erroneous.

Answer(s): C






Post your Comments and Discuss Python Institute PCEP-30-02 exam with other Community members:

PCEP-30-02 Discussions & Posts