added facility for taking n from an iterator