JPNTest PCAP-31-03問題集でリアル試験問題でテストエンジン問題集でトレーニング [Q69-Q93]

Share

JPNTest PCAP-31-03問題集でリアル試験問題でテストエンジン問題集でトレーニング

Python Institute PCAP-31-03テスト問題集とオンライン試験エンジン

質問 # 69
Which of the following sentences are true? (Select two answers)

  • A. tuples may not be stored inside tuples
  • B. lists may be stored inside lists
  • C. lists may not be stored inside tuples
  • D. tuples may be stored inside lists

正解:B、D


質問 # 70
A class constructor (Select two answers)

  • A. can be invoked directly from any of the subclasses
  • B. can be invoked directly from any of the superclasses
  • C. can return a value
  • D. cannot be invoked directly from inside the class

正解:A、D


質問 # 71
What can you do if you don't like a long package path tike this one0 import alpha.beta.gamma.delta.epsiIon.zeta

  • A. you can make an alias for the name using the a 1 i a s keyword
  • B. you can make an alias for the name using die as keyword
  • C. you can shorten it to alpha. zeta and Python will find the proper connection
  • D. nothing; you need to come to terms with it

正解:B


質問 # 72
What is true about Python packages? (Select two answers)

  • A. hashbang is the name of a built-in Python function
  • B. the__name__variable content determines the way in which the module was run
  • C. a package can be stored as a tree of sub-directories/sub-folders
  • D. __pycache__is the name of a built-in variable

正解:C、D


質問 # 73
What is the expected behavior of the following code?

  • A. it outputs 2
  • B. the code is erroneous and it will not execute
  • C. it outputs :
  • D. it outputs 3

正解:B


質問 # 74
What is the output of the following piece of code?

  • A. ant'bat'camel
  • B. antbatcamel
  • C. ant bat camel
  • D. ant"bat"camel

正解:D

解説:


質問 # 75
What is the expected out of the following code of the file named zero_length_existing_file is a zero-length file located inside the working directory?

  • A. 0
  • B. an errno value corresponding to file not found
  • C. 1
  • D. 2

正解:D


質問 # 76
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]

  • A. three
  • B. seven
  • C. five
  • D. zero

正解:B

解説:


質問 # 77
What is true about Object-Oriented Programming in Python? (Select two answers)

  • A. inheritance is the relation between a superclass and a subclass
  • B. an object is a recipe for a class
  • C. encapsulation allows you to protect some data from uncontrolled access
  • D. the arrows on a class diagram are always directed from a superclass towards its subclass

正解:C、D


質問 # 78
What is the expected behavior of the following code?

  • A. it raises an exception
  • B. it outputs 0
  • C. it outputs 2
  • D. it outputs 1

正解:D


質問 # 79
Which of the following expressions evaluate to True? (Select two answers)

  • A. 'phd' in 'alpha'
  • B. 'True' not in 'False'
  • C. str(1-1) in '0123456739'[:2]
  • D. 'deb' not in 'abcde' [::-1]

正解:B、D


質問 # 80
What will the value of the i variable be when the following loop finishes its execution?

  • A. 0
  • B. 1
  • C. the variable becomes unavailable
  • D. 2

正解:D

解説:
Pass only means there are no statements to execute it does not means the variable is unavailable. Try a Print statement Print(i) after the For Loop and there is your result.


質問 # 81
Assuming that the following code has been executed successfully, select the expressions which evaluate to True (Select two answers)

  • A. a() > 2
  • B. a is not None
  • C. b( ) > 2
  • D. a is b

正解:A、B、C


質問 # 82
Which of the following expression evaluate to True? (Select two answers) A)

B)

C)

D)

  • A. Option B
  • B. Option A
  • C. Option D
  • D. Option C

正解:C、D


質問 # 83
What is the expected behavior of the following code?

  • A. it outputs 0
  • B. it outputs 2
  • C. it outputs 1
  • D. it raises an exception

正解:D


質問 # 84
What is the expected behavior of the following code?

  • A. it outputs error
  • B. it outputs list assignment index out of range
  • C. the code is erroneous and it will not execute
  • D. it outputs <class 'IndexError'>

正解:B


質問 # 85
What is the expected behavior of the following code?
x = 8 ** (1/3)
y = 2. if x < 2.3 else 3.
print(y)

  • A. the code is erroneus and it will not execute
  • B. it outputs 3.0
  • C. it outputs 2. 5
  • D. it outputs 2.0

正解:D


質問 # 86
Is it possible to safely check if a class/object has a certain attribute?

  • A. yes, by using the hassattr ( ) function
  • B. yes, by using the hasattr ( ) method
  • C. yes, by using the hasattr attribute
  • D. no, it is not possible

正解:B


質問 # 87
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)

  • A. queue.append(self.get last () + 1)
  • B. self.queue.append(self.get last() +1)
  • C. self.queue.append(self.queue[+1]
  • D. self.queue.append(get_Iast() + 1)

正解:B


質問 # 88
Assuming that the following code has been executed successfully, select the expressions which evaluate to True (Select two answers)

  • A. a() > 2
  • B. a is not None
  • C. b( ) > 2
  • D. a is b

正解:A、B、C


質問 # 89
Which of the following statements are true? (Select two answers)

  • A. UTF-8 is one of the ways of representing UNICODE code points.
  • B. an escape sequence can be recognized by the # sign put in front of it.
  • C. a code point is a point inside the code when execution stops immediately
  • D. ASCII is the name of a character coding standard

正解:C、D


質問 # 90
What would you use instead of XXX if you want to check whether a certain ' key' exists in a dictionary called diet? (Select two answers) II if XXX:
print("Key exists")

  • A. diet['key'] != None
  • B. diet.exists('key')
  • C. 'key' in diet
  • D. 'key' in diet.keys()

正解:C、D


質問 # 91
What is the expected output of the following snippet?

  • A. False lower
  • B. True lower
  • C. False upper
  • D. True upper

正解:B


質問 # 92
What is the expected output of the following code?

  • A. an exception is raised
  • B. 0
  • C. 1
  • D. 2

正解:B


質問 # 93
......


Python Institute PCAP-31-03試験は、Pythonプログラミングの熟練度を証明するための優れた方法です。この認定は、世界的に認められ、IT業界での雇用を求める人々にとって貴重な資産となります。基礎的なプログラミングコンセプトから高度なものまで包括的にカバーしており、初心者から経験豊富なプログラマーまで、どなたでも受験することができます。

 

Python Institute PCAP-31-03問題を提供していますPython Institute PCAP問題集と完璧な解答付き:https://www.jpntest.com/shiken/PCAP-31-03-mondaishu

弊社を連絡する

我々は12時間以内ですべてのお問い合わせを答えます。

オンラインサポート時間:( UTC+9 ) 9:00-24:00
月曜日から土曜日まで

サポート:現在連絡