What does "++" mean? I have seen it used in the responses to some of my questions, and some questions by other people. I know that to manually debug a program, I did this:
1 2 3 4 5 6 7 8 9
int blah()
{
int v=0;
v++;
//stuff....
cout<<"In blah";
cout<<v;
//more stuff....
}
This displayed "In blah" then it displayed how many times the function had been called. I know that however many times the function is called, it adds to the outputted number. Same thing with while loops. However many times it loops, that's how many is outputted.
This is the only way I know how to use "++." I would love to know all the ways to use it.
v++ isn't neccesarily identical to +=1, but it does mean increase by one, for complex types that can be something else. For example, you iterate an iterator using the ++ operator (+=1 wouldn't work).