るりまサーチ

最速Rubyリファレンスマニュアル検索!
24件ヒット [1-24件を表示] (0.069秒)

別のキーワード

  1. _builtin step
  2. numeric step
  3. date step
  4. range step
  5. step

ライブラリ

クラス

検索結果

Enumerator::Lazy#collect {|item| ... } -> Enumerator::Lazy (18126.0)

Enumerable#map と同じですが、配列ではなくEnumerator::Lazy を返します。

...ブロックを指定しなかった場合に発生します。

//emlist[例][ruby]{
1.step.lazy.map{ |n| n % 3 == 0 }
# => #<Enumerator::Lazy: #<Enumerator::Lazy: #<Enumerator: 1:step>>:map>

1.step.lazy.collect{ |n| n.succ }.take(10).force
# => [2, 3, 4, 5, 6, 7, 8, 9, 10, 11]
//}

@see Enumerabl...

Enumerator::Lazy#map {|item| ... } -> Enumerator::Lazy (3026.0)

Enumerable#map と同じですが、配列ではなくEnumerator::Lazy を返します。

...ブロックを指定しなかった場合に発生します。

//emlist[例][ruby]{
1.step.lazy.map{ |n| n % 3 == 0 }
# => #<Enumerator::Lazy: #<Enumerator::Lazy: #<Enumerator: 1:step>>:map>

1.step.lazy.collect{ |n| n.succ }.take(10).force
# => [2, 3, 4, 5, 6, 7, 8, 9, 10, 11]
//}

@see Enumerabl...