• Saves Valuable Time
  • Trusted Accuracy for 12 Years
  • 15-Day Money-Back Guarantee

C++ Equivalent to the VB For Each Loop

VB C++
For Each s As String In StringList //C++11:
for (std::string s : StringList)

//prior to C++11, the conversion is unpleasant (assuming a vector of std::string):
for (std::vector<std::string>::const_iterator s = StringList.begin(); s != StringList.end(); ++s)

Use VB to C++ Converter to convert from VB to C++.     

Copyright © 1997 – 2017 Tangible Software Solutions Inc.