0 True 1

, 2.

1 False 0

, 3.

1 True 0 

, 4.

0 False 1

">
MCQs > IT & Programming > Python > Output of the following Python code? class Son(object): def __init__(self, n): self.n = n def gN(self): return self.n def sE(self): return False class Ploy(Son): def __init__(self, n, eid): super(Ploy, self).__init__(n) self.empID = eid def sE(self): return True def gID(self): return self.empID emp = Ploy("1", "0") print(emp.gN(), emp.sE(), emp.gID())

Python MCQs

What will be the correct output of the following Python code?

class Son(object):

def __init__(self, n):

    self.n = n

     

def gN(self):

    return self.n

 

def sE(self):

    return False

class Ploy(Son):

def __init__(self, n, eid):

    super(Ploy, self).__init__(n)

    self.empID = eid

     

def sE(self):

    return True

     

def gID(self):

    return self.empID

emp = Ploy("1", "0")

print(emp.gN(), emp.sE(), emp.gID())


Answer

Correct Answer:

1 True 0 

Explanation:

Note: This Question is unanswered, help us to find answer for this one

Python Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it

search

Python Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it