worker class c++
C++
#ifndef EMPLOYEE_H
#define EMPLOYEE_H
#include <string>
using namespace std;
class Employee
{
private:
string name; // Employee name
string number; // Employee number
string hireDate; // Hire date
public:
// Default constructor
Employee()
{ name = ""; number = ""; hireDate = ""; }
// Constructor
Employee(string aName, string aNumber, string aDate)
{ name = aName; number = aNumber; hireDate = aDate; }
// Mutators
void setName(string n)
{ name = n; }
void setNumber(string num)
{ number = num; }
void setHireDate(string date)
{ hireDate = date; }
// Accessors
string getName() const
{ return name; }
string getNumber() const
{ return number; }
string getHireDate() const
{ return hireDate; }
};
#endif
Also in C++:
- Title
- binary tree search
- Category
- C++
- Title
- how to output text in c++
- Category
- C++
- Title
- c++ template function
- Category
- C++
- Title
- c++ function return array
- Category
- C++
- Title
- ue4 c++ overlapping functions cpp setup
- Category
- C++
- Title
- how to declare a function in c++
- Category
- C++
- Title
- coronavirus
- Category
- C++
- Title
- command line options in c++
- Category
- C++
- Title
- how to delete an element in vector pair in cpp
- Category
- C++
- Title
- c++ print one line to console instead of multiple
- Category
- C++
- Title
- cout value c++
- Category
- C++
- Title
- arduino falling edge
- Category
- C++
- Title
- c++ main function
- Category
- C++
- Title
- #include
- Category
- C++
- Title
- object reference not set to an instance of an object c#
- Category
- C++
- Title
- c++ program to input and print text using Dynamic Memory Allocation.loop
- Category
- C++
- Title
- cpp loop through object
- Category
- C++
- Title
- initialize map c++
- Category
- C++
- Title
- c++ char to int
- Category
- C++
- Title
- c++ initialize array
- Category
- C++
- Title
- c++ menu selection with arrow keys
- Category
- C++
- Title
- power c++
- Category
- C++
- Title
- c++ function return pointer to itself
- Category
- C++
- Title
- how to turn int into string c++
- Category
- C++
- Title
- how to find the number of cycles in a graph C++
- Category
- C++
- Title
- substr c++
- Category
- C++
- Title
- mysqli connect
- Category
- C++
- Title
- how to find the mode of a vector c++
- Category
- C++
- Title
- pair in c++
- Category
- C++
- Title
- cloud hosting
- Category
- C++
- Title
- c++ argv
- Category
- C++
- Title
- how to print a decimal number upto 6 places of decimal in c++
- Category
- C++
- Title
- sfml base program
- Category
- C++
- Title
- double max value c++
- Category
- C++
- Title
- c++ lettura file
- Category
- C++
- Title
- elseif c++
- Category
- C++
- Title
- std::reverse
- Category
- C++
- Title
- vector pop back
- Category
- C++
- Title
- how to sort vector in c++
- Category
- C++
- Title
- how to iterate through array in c++
- Category
- C++
- Title
- private and public in namespace cpp
- Category
- C++
- Title
- memset
- Category
- C++
- Title
- how to convert a string to a double c++
- Category
- C++
- Title
- pass by reference c++
- Category
- C++
- Title
- pionter in c++
- Category
- C++
- Title
- c++ program for addition of two numbers using functions
- Category
- C++
- Title
- c++ reset stream
- Category
- C++
- Title
- binary tree deletion
- Category
- C++
- Title
- min heap declaration in c++ stl
- Category
- C++
- Title
- error: redefinition of ‘class Customer’
- Category
- C++
- Title
- how read a shader from another file c++
- Category
- C++
- Title
- how to remove maximum number of characters in c++ cin,ignore
- Category
- C++
- Title
- passing a vector to a function c++
- Category
- C++
- Title
- unordered_set c++
- Category
- C++
- Title
- how to find the size of a character array in c++
- Category
- C++
- Title
- how to grab all of user input c++
- Category
- C++
- Title
- setbits
- Category
- C++
- Title
- flake8 max line length
- Category
- C++
- Title
- first fit algorithm
- Category
- C++
- Title
- cpp pi from acos
- Category
- C++
- Title
- variabvles in c++
- Category
- C++
- Title
- queue stl c++
- Category
- C++
- Title
- c++ char print fixed
- Category
- C++
- Title
- range of int
- Category
- C++
- Title
- how to take input in C++ in coding
- Category
- C++
- Title
- How to find the suarray with maximum sum using divide and conquer
- Category
- C++
- Title
- what is sigsegv error in c++
- Category
- C++
- Title
- c++ throw exception
- Category
- C++
- Title
- cin.fail()
- Category
- C++
- Title
- c++ formatting
- Category
- C++
- Title
- correct sequence of compilation process in c++
- Category
- C++
- Title
- how to load from files C++
- Category
- C++
- Title
- what is difffrence between s.length() and s.size()
- Category
- C++
- Title
- invalid types int int for array subscript c++
- Category
- C++
- Title
- creare array con c++
- Category
- C++
- Title
- jump to case label c++
- Category
- C++
- Title
- multiple words C++ in same
- Category
- C++
- Title
- assegnare valori in c++
- Category
- C++
- Title
- stack function in cpp
- Category
- C++
- Title
- Shortest Distance in a Maze
- Category
- C++
- Title
- spicoli
- Category
- C++
- Title
- c++ remove element from vector
- Category
- C++
- Title
- opencv compile c++
- Category
- C++
- Title
- bitset c++
- Category
- C++
- Title
- c++ base 10 to base 2
- Category
- C++
- Title
- knapsack
- Category
- C++
- Title
- chess perft 5
- Category
- C++
- Title
- c++ do you not inherit constructor
- Category
- C++
- Title
- c++ set add element
- Category
- C++
- Title
- what is atoi in strinf
- Category
- C++
- Title
- find vector in c++
- Category
- C++
- Title
- c++ create object
- Category
- C++
- Title
- else if c++
- Category
- C++
- Title
- c++ class method example
- Category
- C++
- Title
- how to iterate through a map in c++
- Category
- C++
- Title
- static variable in c++
- Category
- C++
- Title
- printf c++
- Category
- C++
- Title
- using namespace std in c++
- Category
- C++
- Title
- matrix transpose tiling
- Category
- C++
- Title
- two sum problem in c++
- Category
- C++