A range-over-function iterator lets a producer offer values without first building a whole result slice. Go's iter.Seq type describes a function that calls yield for each value. When yield returns false, the consumer has stopped and the producer must return. Ignoring that signal can waste work or violate the range protocol. Iterators are useful when a caller needs only a prefix, but they do not make every loop faster. The exercises keep their input in memory and make ordering explicit. You will create a bounded sequence, filter it and collect a limited number of values. Empty inputs and an immediate stop are deliberate cases. The checks verify both the yielded values and whether the producer stopped before performing unnecessary work.
The upper bound is excluded.