Check out example codes for "c++ iterate through vectgor". It will help you in understanding the concepts better.

Code Example 1

std::vector<int> vec_of_ints(100);
for (int i = 0; i < vec_of_ints.size(); i++){
 	std::cout << vec_of_ints.at(i) << " "; 
}
std::cout << std::endl;

Learn ReactJs, React Native from akashmittal.com