Q8Comprehension1.5 Marks13 Apr 2025
Passage
Based on the data below, answer the given subquestions.
Consider the following Employee class and its subclass Manager:
```
class Employee:
def __init__(self, name, salary):
self.name = name
self.salary = salary
def update_salary(self, new_salary):
self.salary = new_salary
def print_details(self):
print(f"Employee Name: {self.name}")
print(f"Salary: {self.salary}")
class Manager(Employee):
total_managers = 0
def __init__(self, name, salary, department):
super().__init__(name, salary)
self.department = department
Manager.total_managers += 1
def is_IT_department(self):
return self.department == "IT"
def print_details(self):
super().print_details()
print(f"Manager of Department: {self.department}")
```
What will be the output of the given code?
```
mgr = Manager("Alice", 75000, "HR")
mgr.update_salary(80000)
mgr.print_details()
```