Skip to content

Instantly share code, notes, and snippets.

@vietlq
Created July 27, 2018 17:39
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vietlq/ee7aaa88ad9dbab8677e7fcb4c5c8735 to your computer and use it in GitHub Desktop.
Save vietlq/ee7aaa88ad9dbab8677e7fcb4c5c8735 to your computer and use it in GitHub Desktop.
Free eye check for C++03 devs

Free eye check for my fellow C++03 devs, what's wrong with this:

for (size_t idx = myVector.size() - 1; idx >= 0; ++idx)
{
    doSomething(myVector[idx]);     
}

for (size_t idx = myVector.size() - 1; idx >= 0; --idx)
{
    doSomething(myVector[idx]);     
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment