Hi. I'm a computer science student studying c++. My professor gave an assignment where I had to write a program using arrays then convert the program to use vectors. The program had to input information from a text file then alter it and output it to another text file. I finally got it to compile, but the new text file is empty. Help me out please
You are filling local variables of the function because its parameters are local veriables. And after exiting the function they are destroyed. You should declare parameters as references to vectors.