クラス
- Array (158)
-
Enumerator
:: Lazy (117) - Hash (62)
- Object (48)
- Range (35)
- Struct (38)
-
Zlib
:: GzipReader (24)
モジュール
- Enumerable (338)
- TSort (44)
キーワード
- chunk (24)
- collect (12)
-
delete
_ if (24) - detect (24)
-
each
_ byte (24) -
each
_ strongly _ connected _ component _ from (22) -
enum
_ for (24) - filter (28)
- filter! (28)
- find (24)
-
find
_ all (24) -
find
_ index (36) -
group
_ by (24) -
keep
_ if (48) - map (12)
-
max
_ by (48) -
min
_ by (48) -
minmax
_ by (24) - partition (24)
- reject (48)
- reject! (24)
- select (48)
- select! (48)
-
slice
_ after (22) -
slice
_ before (36) -
slice
_ when (11) -
sort
_ by! (24) - step (21)
-
to
_ enum (24) -
tsort
_ each (22)
検索結果
先頭5件
-
Range
# %(s) -> Enumerator (18217.0) -
範囲内の要素を s おきに繰り返します。
...。
@return ブロックを指定しなかった時かつ数値の Range の時は Enumerator::ArithmeticSequence を返します。
@return ブロックを指定しなかったその他の Range の時は Enumerator を返します。(例: String の Range)
//emlist[例][ruby]{
(1..10).step(3) {|v... -
Range
# %(s) -> Enumerator :: ArithmeticSequence (18217.0) -
範囲内の要素を s おきに繰り返します。
...。
@return ブロックを指定しなかった時かつ数値の Range の時は Enumerator::ArithmeticSequence を返します。
@return ブロックを指定しなかったその他の Range の時は Enumerator を返します。(例: String の Range)
//emlist[例][ruby]{
(1..10).step(3) {|v... -
Enumerator
:: Lazy # chunk {|elt| . . . } -> Enumerator :: Lazy (3149.0) -
Enumerable#chunk と同じですが、配列ではなく Enumerator::Lazy を返します。
...chunk と同じですが、配列ではなく Enumerator::Lazy を返します。
//emlist[例][ruby]{
1.step.lazy.chunk{ |n| n % 3 == 0 }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x007f8bf18118f0>:each>>
1.step.lazy.chunk{ |n| n % 3 == 0 }.take(5).force
# => [[false, [1, 2]]... -
Enumerator
:: Lazy # chunk(initial _ state) {|elt , state| . . . } -> Enumerator :: Lazy (3149.0) -
Enumerable#chunk と同じですが、配列ではなく Enumerator::Lazy を返します。
...chunk と同じですが、配列ではなく Enumerator::Lazy を返します。
//emlist[例][ruby]{
1.step.lazy.chunk{ |n| n % 3 == 0 }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x007f8bf18118f0>:each>>
1.step.lazy.chunk{ |n| n % 3 == 0 }.take(5).force
# => [[false, [1, 2]]... -
Enumerator
:: Lazy # slice _ after {|elt| bool } -> Enumerator :: Lazy (3149.0) -
Enumerable#slice_after と同じですが、配列ではなく Enumerator::Lazy を返します。
...同じですが、配列ではなく Enumerator::Lazy を返します。
//emlist[例][ruby]{
1.step.lazy.slice_after { |e| e % 3 == 0 }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x007fd73980e6f8>:each>>
1.step.lazy.slice_after { |e| e % 3 == 0 }.take(5).force
# => [[1, 2, 3],... -
Enumerator
:: Lazy # slice _ after(pattern) -> Enumerator :: Lazy (3149.0) -
Enumerable#slice_after と同じですが、配列ではなく Enumerator::Lazy を返します。
...同じですが、配列ではなく Enumerator::Lazy を返します。
//emlist[例][ruby]{
1.step.lazy.slice_after { |e| e % 3 == 0 }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x007fd73980e6f8>:each>>
1.step.lazy.slice_after { |e| e % 3 == 0 }.take(5).force
# => [[1, 2, 3],... -
Enumerator
:: Lazy # slice _ when {|elt _ before , elt _ after| bool } -> Enumerator :: Lazy (3148.0) -
Enumerable#slice_when と同じですが、配列ではなく Enumerator::Lazy を返します。
...すが、配列ではなく Enumerator::Lazy を返します。
//emlist[例][ruby]{
1.step.lazy.slice_when { |i, j| (i + j) % 5 == 0 }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x00007fce84118348>:each>>
1.step.lazy.slice_when { |i, j| (i + j) % 5 == 0 }.take(5).force
# => [[... -
Enumerator
:: Lazy # slice _ before {|elt| bool } -> Enumerator :: Lazy (3144.0) -
Enumerable#slice_before と同じですが、配列ではなく Enumerator::Lazy を返します。
...同じですが、配列ではなく Enumerator::Lazy を返します。
//emlist[例][ruby]{
1.step.lazy.slice_before { |e| e.even? }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x00007f9f31844ce8>:each>>
1.step.lazy.slice_before { |e| e % 3 == 0 }.take(5).force
# => [[1, 2], [... -
Enumerator
:: Lazy # slice _ before(initial _ state) {|elt , state| bool } -> Enumerator :: Lazy (3144.0) -
Enumerable#slice_before と同じですが、配列ではなく Enumerator::Lazy を返します。
...同じですが、配列ではなく Enumerator::Lazy を返します。
//emlist[例][ruby]{
1.step.lazy.slice_before { |e| e.even? }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x00007f9f31844ce8>:each>>
1.step.lazy.slice_before { |e| e % 3 == 0 }.take(5).force
# => [[1, 2], [... -
Enumerator
:: Lazy # slice _ before(pattern) -> Enumerator :: Lazy (3144.0) -
Enumerable#slice_before と同じですが、配列ではなく Enumerator::Lazy を返します。
...同じですが、配列ではなく Enumerator::Lazy を返します。
//emlist[例][ruby]{
1.step.lazy.slice_before { |e| e.even? }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x00007f9f31844ce8>:each>>
1.step.lazy.slice_before { |e| e % 3 == 0 }.take(5).force
# => [[1, 2], [...