View the step-by-step solution to:

# Write a class named Employee that holds the following data: name, salary, and years of service. # Create private instance variables to store these...

# Write a class named Employee that holds the following data: name, salary, and years of service.
# Create private instance variables to store these data.
# Do the following in the Employee class:
# (a)  Write an __init_ method that accepts the employee's name, salary and years of service as arguments.
#       Write statements in __init_ to store them in the instance variables.
# (b)  Write three getter methods to retrieve the instance variables.
# (c)  Write a pension method to calculate the monthly pension payout the employee will receive in retirement:
#       monthly pension payout = salary * years of service * 0.0015.
#       The only parameter of this method is self.  No arguments need to be passed to this method when this method is called.
#       It uses data stored in the instance variables to calculate monthly pension payout.
#       This method returns the monthly pension payout.
#
# The main function of this program is partially written...
# Variables are created for name, salary and years of service...
# Do the following:
#      (a) Use the data provided to create an Employee object.
#      (b) Write statements to display the three instance variables of the Employee objects
#      (c) Call the Employee object's pension method to calculate the monthly pension payout of this employee.
#           Write a statement to display it.

#def main():
#   empName = str(input("What is your namejQuery20006700749567500559_1525657085820? "))
#   empSalary = int(input("What is your yearly salary??? "))
#   empYearsOfService = str(input("How long have you been employed with the company??? "))

#    name = "Joe Chen"
#    salary = 80000
#    years_of_service = 30


# Insert code here to define class Employee
#class Employee:

#    def __init__(self, empName, empSalary, empYearsOfService):
#       self.__Name = empName
#       self.__Salary = empSalary
#       self.__Years = empYearsOfService
#       get_Name()
#       get_Salary()
#       get_Years()


# Insert code here to create an Employee object
#   def get_Name()


#    def get_Salary()




#    def get_Years()

# Insert code here to display the object's instance variables

#def displayEmployeeInfo (Name, Salary, Years)
#    def set_Name(self, Name):
#        self.__Name = Name

#    def set_Salary(self, Salary):
#        self.__Salary = Salary

#    def set_Years(self, Yprice):
#        self.__Years = YearsOfService

#   def get_Name(self):
#        return self.__Name

#    def get_Salary(self):
#        return self.__Salary

#    def get_Years(self):
#        return self.__Years

# print(Name, Salary, Years)


Howdy...

If this stuff is for real then I STILL need some help here...

The class is "QED" but here I sit working on this last set of "Problems"

Please see "Comment" Section of my code above for an idea of what I am seeking as a final result...

Any help would be appreciated... complete solution would be Outstanding... as I really want to understand this Class stuff completely.


Thanks Much

Recently Asked Questions

Why Join Course Hero?

Course Hero has all the homework and study help you need to succeed! We’ve got course-specific notes, study guides, and practice tests along with expert tutors.

-

Educational Resources
  • -

    Study Documents

    Find the best study resources around, tagged to your specific courses. Share your own to gain free Course Hero access.

    Browse Documents
  • -

    Question & Answers

    Get one-on-one homework help from our expert tutors—available online 24/7. Ask your own questions or browse existing Q&A threads. Satisfaction guaranteed!

    Ask a Question