Hi everyone!
I'm pretty new to c++ (Like yesterday) and I downloaded Code::Blocks and started to get to work on learning it. I ran into a problem though for some reason this code below will say it found the person even though I did not even put the correct fullname to search for.
Two other questions I had number one being is there a better way to check if the person your looking for is in an []?
Secondly on the input of the console were it assigns the lookingForFullName if I was to put a space in it only takes in the first arg. Any way to make that take in all args following the first?
Thank you for reading and I hope you can help!
is there a better way to check if the person your looking for is in an []
If the array is sorted, yea.
Secondly on the input of the console were it assigns the lookingForFullName if I was to put a space in it only takes in the first arg. Any way to make that take in all args following the first?
I ran into a problem though for some reason this code below will say it found the person even though I did not even put the correct fullname to search for.
If you had said "It won't find the person, no matter what fullname I input," I would've believed that. As it is, the behavior you describe can't happen as the only value any database in the employees array has for the member fullname is an empty string.