Exercise3.24

notice that the .end() point to the next element of the last element in
the vector, not the last element.