Welcome to ExamTopics
ExamTopics Logo
- Expert Verified, Online, Free.
exam questions

Exam PCPP-32-101 All Questions

View all questions & answers for the PCPP-32-101 exam

Exam PCPP-32-101 topic 1 question 19 discussion

Actual exam question from Python Institute's PCPP-32-101
Question #: 19
Topic #: 1
[All PCPP-32-101 Questions]

Select the true statements related to PEP 8 programming recommendations for code writing. (Choose two.)

  • A. You should use the not ... is operator (e.g. if not spam is None:), rather than the is not operator (e.g. if spam is not None:), to increase readability.
  • B. You should make object type comparisons using the isinstance() method (e.g. if isinstance(obj , int):) instead of comparing types directly (e.g. if type(obj) is type(1)).
  • C. You should write code in a way that favors the CPython implementation over PyPy, Cython, and Jython.
  • D. You should not write string literals that rely on significant trailing whitespaces, as they may be visually indistinguishable, and certain editors may trim them.
Show Suggested Answer Hide Answer
Suggested Answer: BD 🗳️

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
2211094
2 months ago
AB are valid answer based on PEP 8
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...