http://www.eskimo.com/~scs/cclass/notes/sx1b.html (for loop)