I am trying to fully understand for loops in c/c++. The more i read, the more i find of ways to write for loops. Its seems complicated, with all the ways to write a for loop. And remembering each one, and each one's syntax. First of all, are there any more ways to write a for loop that is not included?
what is ::size_type mean?
based on yours i also added auto to replace std::vector<int>::size_type. Is that the purpose of auto, is to replace syntax for easier reading?
1 2 3
for ( auto i = 0; auto n = v.size() - i; i++ ){
std::cout << v[i] << ' ';
}