Alright I need help again, I am trying to to pass it to my class with a vector now, and am very confused.
here is my class:
using namespace std;
void setEmployeeLName(string lName);
void setEmployeeFName(string fName);
void setEmployeeMSal(double monthlySal);
string getEmployeeLName() const;
string getEmployeeFName() const;
double getEmployeeMSal() const;
void displayEmployeeInfo() const;
here is my problem, I know how to pass an array element to a function. but how do I pass it with a vector? I know i can use [ i ] but if I do that then if I am correct the vector doesn't do a range check. But if I use push_back it will add elements as needed.
so if I am trying to assign a value to say
how would I use that with my class so that it will always add the element to the next spot?