# Split string into iterator

* split

* [split](https://doc.rust-lang.org/std/primitive.str.html#method.split) method returning an iterator called [Split](https://doc.rust-lang.org/std/str/struct.Split.html).

* [split_whitespace](https://doc.rust-lang.org/std/primitive.str.html#method.split_whitespace) method returning an iterator called [SplitWhitespace](https://doc.rust-lang.org/std/str/struct.SplitWhitespace.html).

{% embed include file="src/examples/vectors/split-string-into-iterator/src/main.rs" %}
{% embed include file="src/examples/vectors/split-string-into-iterator/out.out" %}


