Fairly new to C++. Referring to this snippet of code:
for (std::vector<int>::iterator it = myvector.begin() ; it != myvector.end(); ++it)
std::cout << ' ' << *it;
std::cout << '\n';
Although iterators are not necessarily pointers (although for
std::vectors most non-debug implementations implement them as thin wrappers around pointers),
std::vector is guaranteed to have its elements contiguous in memory. Which implies that YES, every element has a distinct memory location.