Initial commit

This commit is contained in:
Michael Reber
2019-11-15 12:59:38 +01:00
parent 40a414d210
commit b880c3ccde
6814 changed files with 379441 additions and 0 deletions
@@ -0,0 +1,25 @@
Access a vector using an iterator.
#include <iostream>
#include <vector>
using namespace std;
int main()
{
vector<int> v;
int i;
for(i = 0; i <10; i++)
v.push_back(i);
for(i = 0; i <10; i++)
cout << v[ i ] << " ";
cout << endl;
vector<int>::iterator p = v.begin();
while(p != v.end()) {
cout << *p << " ";
p++;
}
return 0;
}