I know how to do this in other languages, but not C++, which I am forced to use here.
I have a Set of Strings that I\'m printing to out in a list, and they need a co
I would go with something like this, an easy solution and should work for all iterators.
int maxele = maxele = v.size() - 1; for ( cur = v.begin() , i = 0; i < maxele ; ++i) { std::cout << *cur++ << " , "; } if ( maxele >= 0 ) { std::cout << *cur << std::endl; }