Hello, everyone! It's my first post on this forum~! And I'm new to C++.
I did look for solutions from previous posts to my question, but I failed to find one.
My programme reads student_numbers (string, e.g. 123456) from one txt file.
And I want to open txt files with the name <student_number>.
People suggested infile.open(student_number.c_str());
However, it does not work in my case. If I use the above method, am I missing ".txt"? And how should I do it?