[arrays] Modify iterators for better speed.