[Edited: 2:34pm. Changed topic name to more accurately reflect problem.]
Hi everyone,
I have a very simple program that gives a runtime error. I have identified the line where I get the error, but for the life of me, I can't figure out why I get the error. Can someone please please help me out? I will be forever grateful.
To the best of my knowledge, the contructor for a class populates a vector, but when a member function tries to access that vector, there is no data in it.
The size of vV.at(i) is zero (examine it with cout << vV.at(i).size();) . The at function will throw an out_of_range exception if the requested position is equal to or greater than the size.