Write the class definition for a class named employee

Assignment Help Other Subject
Reference no: EM13283322

Step 1:

Write the class definition for a class named Employee. The class should include data members for an employee object%u2019s name and salary. (The salary will be an integer). The class should contain two member functions: the constructor and a function that allows a program to assign values to the data members.

Step 2:

Add two member functions to the Employee class. One member function should allow any program using an employee object to view the contents of the salary data member. The other member function should allow the program to view the contents of the employee name data member. (Hint: Have the member function simply return the contents of the appropriate data member.)

Sep 3:

Add another member function to the Employeeclass. The member function should calculate an employee object%u2019s new salary, based on a raise percentage provided by the program using the object. Before calculating the raise, the member function should verify that the raise percentage is greater than or equal to zero. If the raise percentage is less than zero, the member function should display an error message.

Step 4:

The instructions to create an employee object, assign values to the object, display the name and current salary, calculate the new salary, and then display the new salary are missing from the program. Complete the program, using these comments as a guide.

Reference no: EM13283322

Questions Cloud

Differences in normal aging-primary aging-seconday aging : Describe the key differences between normal aging, primary aging, and secondary aging.  What control do we have over each of these processes, and how are they influenced by internal changes, external changes, and daily life exposures?  Reflect on the..
Build an organizational strategic plan : Strategic planning and the tradtional steps to build an organizational strategic plan
Navy vessels by guessing their locations on a grid : Write a program to play a game in which you try to sink a fleet of five navy vessels by guessing their locations on a grid. The program uses random numbers to position its ships on a 15 X 15 grid.
Deal-closing techniques : NOW THAT SHE HAD TO, JEAN M C GUIRE WASN'T sure she could. Not that she didn't understand what to do. Wright Boazman, sales director for Sunrise Land Developers, had made the step clear enough when he described a variety of effective "deal..
Write the class definition for a class named employee : Write the class definition for a class named Employee. The class should include data members for an employee object%u2019s name and salary. (The salary will be an integer). The class should contain two member functions: the constructor and a function..
Briefly discuss the issues around the use of repos : Briefly discuss the issues around the use of (and reliance on) repos by banks.
Hospitals and health systems : Debate the need for hospitals from the perspective in the early 1900s and in the 21st century. You are a health care professional looking to serve your community and you decided to open a hospital with a couple of individuals who want to provide this..
Develop an envisioned methodology : Support your paper with a minimum of 7 resources. In addition to these specified resources, other appropriate scholarly resources, including older articles, may be included.
Modify each practice to promote high quality service : Identify three human resource practices that can impede customer service employees from delivering high quality service. Describe how you would modify each practice to promote high quality service.

Reviews

Write a Review

Other Subject Questions & Answers

  Create mission-vision statement for healthcare organization

Create a mission and vision statement for a healthcare organization. Determine 3 specific strategic goals that align with the idea in the 2 statements.

  Empathy-altruism hypothesis

Can you think of situations when the egoistic model of altruism seems most likely correct? What about the empathy-altruism hypothesis?

  Analysis of audience attitudes-values

How can an analysis of audience attitudes, values, and beliefs be used to evaluate the connotative implications of certain words?

  Can followers influence upward?

Can followers influence upward? is it possible to solve organizatitonal problems by using this process? provide two examples to support your view.

  Discuss the result of social structure

Bradley Wright: "Merton's Strain Theory, Crime, and My Pants." This article talks about the kinds of responses that one might expect when the "normal" legitimate means to acquiring the "good" stuff in life is blocked.

  Procedural and declarative knowledge

Need an illustration of procedural knowledge and of declarative knowledge.

  Financial costs of chronic illness

You will locate a credible website, preferably a government website that chronicles the financial costs of the chronic condition you have been focusing on this term.

  Explain the concept of virtualization

Explain the concept of virtualization, with respect to networking (LAN or WAN) as well as with respect to the virtualization of servers. How is virtualization technology evolving, and what are some examples of recent advances in this area?

  Identifying the critical activities in network

The condominium manager identified the following renovation activities and their estimated times.Prepare a project network. Identify the critical activities.

  A researcher hypnotizes twenty volunteers

A researcher hypnotizes twenty volunteers an suggests to them that they will become more creative. Later the researcher compares stories these people write to stories written by 20 other people, and reports a difference. The main problem with this st..

  Making search legal

Over 200 word essay and reference the explains what makes a search legal.

  What specific factors serve as the basis for victimization

Provide a brief description as to what specific factors serve as the basis for victimization; for example, race, religion, or sexual orientation, Identify applicable specific case examples. List restorative justice models that could be used for your ..

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