Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Exercise: iterators - alter

  • Implement the alter functions as an iterator that will return
1
-2
3
-4
5
-6
...
  • Optionally provide a start and end parameters
  • start defaults to 1
  • end defaults to unlimited