Question: or the class Employee example provided in tutorial 3.1.5, what code segments could be added to keep track of the number of salary creases that

 or the class Employee example provided in tutorial 3.1.5, what codesegments could be added to keep track of the number of salarycreases that have occurred for an employee? def _init__(self, fname, lname, empid,title, sal): self.salaryincreases= def increase_salary(self, percent): if percent > : self.set_salary(self.salary +self.salary * percent) self.salaryincreasest=1 else: print("Increase of salary must be greater than") def get_salary_increases(self): return self.salaryincreases def _init_(fname, lname, empid, title, sal): self.salaryincreases = def increase_salary(percent): if percent > : self.set_salary(salary + self.salary *

or the class Employee example provided in tutorial 3.1.5, what code segments could be added to keep track of the number of salary creases that have occurred for an employee? def _init__(self, fname, lname, empid, title, sal): self.salaryincreases= def increase_salary(self, percent): if percent > : self.set_salary(self.salary + self.salary * percent) self.salaryincreasest=1 else: print("Increase of salary must be greater than ") def get_salary_increases(self): return self.salaryincreases def _init_(fname, lname, empid, title, sal): self. salaryincreases = def increase_salary(percent): if percent > : self.set_salary(salary + self.salary * percent) self.salaryincreases +=1 else: print("Increase of salary must be greater than 0."I ) def get_salary_increases(): return self.salaryincreases def _init__self, fname, lname, empid, title, sal): salaryincreases = lestion 2 Mark this question the Employee Class Program in the Unit 3 Finishing the Employee Class Program tutorial, what if we need the capability to change id for employees? What information is needed to perform this task and what code segment implements obtaining it in a method? Employees file information and the new id def upd_salary(): employees = read_employees() new_id = input("Enter the new id of the employee: ") Employee id and the new id def upd_id(employees): empid = input("Enter the employee ID: ") new_id = input("Enter the new id of the employee: ") Employee id def upd_id(employees): empid = input("Enter the employee ID: ") def upd_salary(employees): empid = input("Enter the employee ID: ") The new id def upd_salary(employees): new_id = input("Enter the new id of the employee: ") Question 4 Mark this question If programming a class to represent a geometry calculator, which class containing methods with parameters could be used to calculate the volume of a sphere with radius r, the volume of a cone with radius rand height h; and increment the total number of calculations performed? class Geo_Calc: def _init_(self): self.numofcalcs =0 def clearTotal(self): self.numofcalcs =0 def returnTotal(self): return self.numofcalcs def volume_of_sphere(self): self.numofcalcs += 1 return (4/3) math.pi rrr def volume_of_cone(self): self.numofcalcs +=1 return (1/3) math.pi rrh class Geo_Calc: def _init__(self): self.numofcalcs =0 def clearTotal(self): self. numofcalcs = def returntotal (self): return self.numofcalcs def volume_of_sphere(self,r): self. numofcalcs +=1 return (4/3) math.pi rrr def volume_of_cone (self,r,h) : self. numofcalcs t=1 return (1/3) math.pi rrh class Geo_Calc: def _init_(self): self.numofcalcs =0 def clearTotal(self): self.numofcalcs = 0 def returnTotal(self): return self.numofcalcs def volume_of_sphere(self,r): numofcalcs +=1 return (4/3) * math.pi rrr def volume_of_cone(self, r,h): numofcalcs +=1 return (1/3) math.pi rrh class Geo_Calc: def _init__(self): self.numofcalcs =0 def clearTotal(self): self.numofcalcs =0 def returntotal (self): return self.numofcalcs def volume_of_sphere(self): numofcalcs +=1 return (4/3) math.pi * rrr def volume_of_cone(self): numofcalcs +=1 return (1/3) math.pi * rrh Which code segment could be used to properly implement a custom module called temp_celsius_rankine.py to convert temperature etween Celsius and Rankine scales? In file temp_celsius_rankine.py place In file temperature.py place In file temperature.py place mum Converts temperatures between Celsius and Rankine mun def to_rankine(celsius): rankine = (celsius 9/5 ) +491.67 return rankine def to_celsius(rankine): celsius = (rankine - 491.67 ) * 5/9 return celsius

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!