Write program that creates an object of productionwork class

Assignment Help Python Programming
Reference no: EM131663748

Programming Assignment

Write an Employee class that keeps data attributes for the following pieces of information:

• Employee Name
• Employee Number

Next, write a class named ProductionWorker that is a subclass of the Employee class. The ProductionWorker class should keep data attributes for the following information:

• Shift Number (an integer 1 or 2)
• Hourly Pay Rate

The workday is divided into two shifts: day and night. The shift attribute will hold an integer value representing the shift that the employee works. The day shift is shift 1 and the night shift is shift 2. Write the appropriate accessor and mutator methods for each class.

Once you have written the classes, write a program that creates an object of the ProductionWorker class and prompts the user to enter data for each of the object's data attributes. Store the data in the object and then use the object's accessor methods to retrieve it and display it on the screen.

Add an __str__ method to the ProductionWorkerclass that will print the attributes from both classes in a readable format. In the main part of the program, create one more ProductionWorker object, assign values to the attributes and print both objects using the print statement.

Reference no: EM131663748

Questions Cloud

Calculate the total manufacturing cost per unit for quarter : Calculate the total manufacturing cost per unit for the second and third quarter assuming the company allocates manufacturing overhead costs based on an annual.
Security features of file system type : Select three of the most common types of file systems and describe the security features of each file system type.
Most common threats to web browsers : Discuss what are the most common threats to Web browsers. What are the most damaging ones and why?
Define physical obstructions such as furniture and equipment : What support should an aged care worker provide to an older person to alleviate or prevent the following risks
Write program that creates an object of productionwork class : Write a program that creates an object of the ProductionWorker class and prompts the user to enter data for each of the object's data attributes.
What do you think is the intended purpose of honeypots : What do you think is the intended purpose of Honeypots? What benefits could be rendered from setting up a honeypot in an organization?
Retrieve data from a database for a web application : What is a parameterized query, and why would you want to use one to retrieve data from a database for a web application?
Research using the course learning materials : Research using the course learning materials, valid internet sources, and related personal experience, the advantages and disadvantages of utilizing CIDR.
Discuss techniques used by malware developers disguise code : Please discuss the techniques used by malware developers to disguise their code and prevent it from being analysed

Reviews

Write a Review

Python Programming Questions & Answers

  Write a python program to implement the diff command

Without using the system() function to call any bash commands, write a python program that will implement a simple version of the diff command.

  Write a program for checking a circle

Write a program for checking a circle program must either print "is a circle: YES" or "is a circle: NO", appropriately.

  Prepare a python program

Prepare a Python program which evaluates how many stuck numbers there are in a range of integers. The range will be input as two command-line arguments.

  Python atm program to enter account number

Write a simple Python ATM program. Ask user to enter their account number, and print their initail balance. (Just make one up). Ask them if they wish to make deposit or withdrawal.

  Python function to calculate two roots

Write a Python function main() to calculate two roots. You must input a,b and c from keyboard, and then print two roots. Suppose the discriminant D= b2-4ac is positive.

  Design program that asks user to enter amount in python

IN Python Design a program that asks the user to enter the amount that he or she has budget in a month. A loop should then prompt the user to enter his or her expenses for the month.

  Write python program which imports three dictionaries

Write a Python program called hours.py which imports three dictionaries, and uses the data in them to calculate how many hours each person has spent in the lab.

  Write python program to create factors of numbers

Write down a python program which takes two numbers and creates the factors of both numbers and displays the greatest common factor.

  Email spam filter

Analyze the emails and predict whether the mail is a spam or not a spam - Create a training file and copy the text of several mails and spams in to it And create a test set identical to the training set but with different examples.

  Improve the readability and structural design of the code

Improve the readability and structural design of the code by improving the function names, variables, and loops, as well as whitespace. Move functions close to related functions or blocks of code related to your organised code.

  Create a simple and responsive gui

Please use primarily PHP or Python to solve the exercise and create a simple and responsive GUI, using HTML, CSS and JavaScript.Do not use a database.

  The program is to print the time

The program is to print the time in seconds that the iterative version takes, the time in seconds that the recursive version takes, and the difference between the times.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd