Commit eefcc06048da359941147fb9fac66ce69bfd830b

Authored by Grzegorz Jabłoński
1 parent 8bd0a931

Fixed end iterator

examples09/02-iterator/foreach.cpp
@@ -42,7 +42,7 @@ Iterator Collection::begin() @@ -42,7 +42,7 @@ Iterator Collection::begin()
42 42
43 Iterator Collection::end() 43 Iterator Collection::end()
44 { 44 {
45 - return Iterator(Collection::size-1,this); 45 + return Iterator(Collection::size,this);
46 } 46 }
47 47
48 int main() 48 int main()