That line stores data from fin into the variables employeeid, hoursworked, hourlyrate. If you had anything in there before (which you did - you're using them to store the user's input), that previous data is overwritten.
employeeid != 1234, 5678, 9098, 7654, 3210
That's just a complete misunderstanding of what the , syntax dies. Don't use it. It does not mean what you think it means here.
Moschops, I was thinking along those lines last night. I tried removing the employeeid from the fin statement to see if that worked, but I got the same result.
(fin>>hoursworked>>hourlyrate)
Is that how it should read? Am I missing something else?
And slurpee123abc, since it is a C++ Course, I doubt doing it in Python will help me :p
That won't do you much good, given that the text file contains the employee numbers. They will still be read in.
I think you might find things a bit easier to think about if you have two variables; employeeNumberToFind and employeeNumber. The first will be provided by the user, the second read in from the text file.
Well I have been following up the exchange here and I figure what Moschops trying to tell you and you probably getting it at the same time you probably don't even have enough time to work on this.
This code could do most of the work except one thing missing and that is instead of matching the first 4 digit of the line with the user input try to match it with the whole line. You probably could figure that out, i will c if i could work on it and update u.... don't count on me though
Actually, abiyek, I have been working on this since I read Moschops last post earlier this afternoon, and I haven't had time to come back and check for any other replies. But, I sincerely thank you for your input. That phase of the program ended up looking pretty much just like yours. It was great figuring it out with helpful hints, rather than just getting the answer fed to me. But, trust me, I was nervous I wasn't going to finish in time. Too bad you weren't around here yesterday! Just kidding :p Thanks a lot!
And Moschops, I really appreciate your continued attention. Your replies really helped me to finish this assignment by actually figuring out what I was doing wrong, so thank you very much!