scan all array elements