Hi
I was wondering if someone could help with linked list. I'm trying to read i a text file in this format:
ID Name PR Salary
339 GOERGE 4 26000
221 SANDY 4 22600
101 RONNY 3 35250
and put it in a linked list. I have this much so far.
struct employee
{
int ID;
char name[10];
int performance;
int curSalary;
employee *next;
};
int main()
{
ifstream inFile;
employee *head, *current = NULL;
inFile.open("InputFile.txt");
if (!inFile)
{
cerr << "Unable to open file datafile.txt" << endl;
exit(1); // call system to stop
}
inFile.getline(inFile,80);
while(!inFile.eof())
{
}
}