Implement forward iterator.

Closes #5.