lastOrOption method
Consumes the iterator and returns the last element.
Implementation
@override
Option<T> lastOrOption() {
if (moveNext()) {
var last = current;
while (moveNext()) {
last = current;
}
return Some(last);
}
return None;
}