Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

In C++ please 2. In the following program an employee of a company is represented by an object of type employee consisting of a name,

image text in transcribedimage text in transcribed

In C++ please

2. In the following program an employee of a company is represented by an object of type employee consisting of a name, employee id, employee salary and the workday starting time. The starting time is a class time 24 object. Implement the class employee. Declaration of Employee and Time Classes /* File: employeetime.h Hlustrates composition of classes / #ifndef EMPLOYEETIME H #define EMPLOYEETIME H #include #include using namespace std; class time 24 { private: int hour; int minute: // hour between 0 and 23 // minute between 0 and 59 public: time 24 (int h, int m); void write (ostream & out) const; // constructor // prints hour: minute to out class employee { private: string name; // last name int id: // employee id number float salary; // employee salary time 24 start; // workday start time public: employee (string n, int i, float s, int h, int m); void write (ostream & out) const; #endif /* EMPLOYEETIME_H / Implementation of Employee and Time Classes /* File: employeetime.cpp Implementation of classes employee and time */ #include "employeetime.h" I Implementation of time 24 m m time 24 :: time 24 (int h, int m) hour = h; minute = m; void time 24 :: write (ostream &out) const out

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Contemporary Issues In Database Design And Information Systems Development

Authors: Keng Siau

1st Edition

1599042894, 978-1599042893

More Books

Students also viewed these Databases questions

Question

2. In what ways have your peers and your parents helped shape you?

Answered: 1 week ago

Question

Have I incorporated my research into my outline effectively?

Answered: 1 week ago