PCAP-31-03 Exam QuestionsBrowse all questions from this exam

PCAP-31-03 Exam - Question 54


What is true about Python class constructors? (Choose two.)

Show Answer
Correct Answer: BD

In Python, a class can have only one constructor method, defined by __init__. Therefore, it is true that there can only be one constructor in a Python class. Additionally, the __init__ method must not return a value other than None; its purpose is to initialize the object's attributes, not to produce a result.

Discussion

2 comments
Sign in to comment
kstrOptions: BD
Jul 12, 2024

BD the correct answer

DKAT2023Options: AB
Jul 12, 2024

A and B are corrects