How to read files input using the same ifstream object in CPP
I’m currently working on a problem that takes 2 matrix as its input.
I notice that when I use the same ifstream object to open 2 file, values of the second file get weird when I print it out.
This is not the case if I use the second ifstream object to take the input. I wanted to know what is happening and why can’t I use just one.
`
int main(){
ifstream fin;