time and count measurement for Python iterators