What will be the output of the following Python code? class tester: def __init__(self, id): self.id = str(id) id=”224″ >>>temp = tester(12) >>>print(temp.id)

Questions & AnswersCategory: Programming LanguageWhat will be the output of the following Python code? class tester: def __init__(self, id): self.id = str(id) id=”224″ >>>temp = tester(12) >>>print(temp.id)
Geek Boy Staff asked 2 years ago

What will be the output of the following Python code?

class tester:    
    def __init__(self, id):
        self.id = str(id)
        id="224"
>>>temp = tester(12)
>>>print(temp.id)

a. 12
b. 224
c. None
d. Error