method iter.chain
All elements of self, then all elements of other.
Example:
fn main() io {
print("{[1, 2].iter().chain([3].iter()).collect()}")
}Output
[1, 2, 3]
pub(api) move fn chain(other: iter<T>) -> iter<T>Complexity. O(1) per element.
Since. 1.0.0-beta
Parameters
| Name | Type |
|---|---|
other | iter<T> |
Returns
iter<T>
Effects
none declared (pure unless the body says otherwise)
Defined in: std/core/iter.oxl:345