Question: The following python code has a missing attribute. If we run this code as it is now, we will get an error message. Debug the
The following python code has a missing attribute. If we run this code as it is now, we will get an error message. Debug the code by adding the missing attribute and run the program and get the output.
#Encapsulaiton
class Employee:
def __init__(self):
self.__ssn = '307 878 876'
def pirntInfo(self):
print(self.__ssn)
employee1 = Employee()
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
