I have no idea what I am doing wrong. This is supposed to read names and years from a txt file and them put them into two arrays which should then be sorted. Where am I going wrong?
But, your compiler does. And it told you when you attempted to compile it. Generally, you'll want to share those sorts of things with anyone who might help you.
Line 29 is illegal. Line 34 is a syntax error. Arrays don't have members begin or end. Perhaps you meant to use a vector?
Considering we don't have the txt file nor what's in it It is kind of hard for us to help. What exactly does it do when you run this program? Does it continue to get user input?