I\'m trying to implement a custom iterator for the last couple of hours but couldn\'t figure out what is wrong. I looked up several posts on SO and even refered to some