|
iterator_countCount the elements in an iterator Description
int iterator_count(Traversablearray
$iterator )
Count the elements in an iterator.
iterator_count is not guaranteed to retain the current
position of the Parameters
Return Values
The number of elements in Changelog
Examples
Example #1 iterator_count example
The above example will output: int(4) Example #2 iterator_count modifies position
The above example will output: string(3) "one" int(3) NULL Example #3 iterator_count in foreach loops
The above example will output: 0: one (3) |