上QQ阅读APP看书,第一时间看更新
Filtering and transforming sequences efficiently
While in the previous recipe we discussed implementing a custom iterator, it's now time to make use of the functions they provide. Iterators can transform, filter, reduce, or simply convert the underlying elements in a single go, thereby making it a very efficient endeavor.