Okay so I completed a homework assignment that required me to open an input file. So everything worked out and I put the .txt file in the debug folder of my project and everything works. Sidebar: I'm using Xcode. My question is will the input file be transferred with the project when I upload the .cpp file online so when my teacher test the project it works for her like it worked on mine?
If you only upload the .cpp then no. I would suggest you zip your project (remove the .sdf file, it only takes space and is not needed) and send you teacher the zippes file.