4631件ヒット
[1-100件を表示]
(0.065秒)
クラス
-
ARGF
. class (98) - Array (513)
- Bignum (30)
- Class (11)
- Complex (99)
- Data (10)
- Dir (17)
-
Encoding
:: Converter (66) -
Encoding
:: InvalidByteSequenceError (22) -
Encoding
:: UndefinedConversionError (22) - Enumerator (149)
-
Enumerator
:: ArithmeticSequence (60) -
Enumerator
:: Lazy (288) - Exception (11)
- File (58)
-
File
:: Stat (77) - Fixnum (27)
- Float (332)
- Hash (243)
- IO (218)
- Integer (100)
- MatchData (180)
- Method (11)
- Module (195)
- NilClass (22)
- Numeric (182)
- Object (79)
- Proc (11)
-
Process
:: Status (33) - Random (33)
- Range (56)
- Rational (288)
- Regexp (30)
-
RubyVM
:: InstructionSequence (31) - String (387)
- Struct (28)
- Symbol (19)
- Thread (63)
-
Thread
:: Backtrace :: Location (66) - Time (22)
- TracePoint (11)
- UnboundMethod (11)
モジュール
- Enumerable (408)
- GC (11)
- Warning (3)
キーワード
- % (29)
- & (11)
- * (28)
- ** (28)
- + (34)
- - (39)
- -@ (19)
-
/ (28) - < (11)
- <= (11)
- <=> (22)
- == (52)
- === (5)
- > (11)
- >= (11)
- >> (11)
- [] (88)
-
abort
_ on _ exception= (11) -
absolute
_ path (22) - all? (13)
- allocate (11)
- angle (22)
- any? (14)
-
append
_ features (11) - arg (22)
- atime (22)
- attr (33)
-
attr
_ accessor (11) -
attr
_ reader (11) -
attr
_ writer (11) - autoload (11)
-
backtrace
_ locations (33) -
base
_ label (11) - begin (17)
- birthtime (11)
- bsearch (22)
-
bsearch
_ index (9) - byteindex (2)
- byteoffset (4)
- byterindex (2)
- bytes (7)
- captures (11)
- ceil (26)
- chain (6)
- chars (7)
- chunk (33)
-
chunk
_ while (19) - codepoints (7)
- coerce (11)
- collect (33)
- collect! (11)
-
collect
_ concat (11) - combination (22)
- concat (38)
- conjugate (11)
-
const
_ source _ location (5) - convert (11)
- convpath (11)
- ctime (11)
- cycle (22)
-
deconstruct
_ keys (2) -
delete
_ at (11) -
delete
_ if (22) - denominator (55)
-
deprecate
_ constant (9) -
destination
_ encoding (33) -
destination
_ encoding _ name (22) - detect (11)
- directory? (11)
- div (6)
- divmod (11)
- downto (11)
- drop (11)
-
drop
_ while (22) - each (155)
-
each
_ byte (33) -
each
_ char (33) -
each
_ child (6) -
each
_ codepoint (11) -
each
_ cons (11) -
each
_ entry (11) -
each
_ grapheme _ cluster (7) -
each
_ index (11) -
each
_ key (11) -
each
_ line (66) -
each
_ pair (11) -
each
_ slice (11) -
each
_ value (11) -
each
_ with _ index (11) -
each
_ with _ object (11) - end (17)
-
enum
_ for (22) - eql? (24)
- fdatasync (11)
- fdiv (28)
- feed (11)
-
fetch
_ values (18) - filter (30)
- filter! (12)
-
filter
_ map (10) - find (11)
-
find
_ all (22) -
find
_ index (22) - first (12)
-
flat
_ map (11) - flatten (22)
- flatten! (11)
- flock (11)
- floor (27)
-
garbage
_ collect (11) - grep (33)
-
grep
_ v (31) - gsub (44)
- gsub! (44)
- hash (13)
- index (29)
- inspect (33)
- isatty (11)
-
keep
_ if (22) - key (11)
- label (11)
- last (12)
- lazy (11)
- lines (42)
- lstat (11)
- map (33)
- map! (11)
- match (55)
- match? (24)
-
max
_ by (22) -
min
_ by (22) -
minmax
_ by (11) - modulo (17)
- mtime (11)
-
named
_ captures (11) - negative? (26)
- next (11)
-
next
_ float (10) -
next
_ values (11) - none? (13)
- numerator (55)
- offset (22)
- one? (13)
- pack (19)
- path (40)
- peek (11)
-
peek
_ values (11) - permutation (22)
- phase (22)
- positive? (17)
-
post
_ match (11) -
pre
_ match (11) -
prepend
_ features (11) -
prev
_ float (10) -
primitive
_ convert (44) - printf (22)
- private (23)
-
private
_ class _ method (15) -
private
_ constant (11) -
private
_ instance _ methods (11) -
private
_ method _ defined? (11) -
private
_ methods (11) - quo (22)
- rand (33)
- rationalize (99)
- reject (44)
- reject! (22)
- remainder (3)
-
remove
_ const (11) - reopen (22)
-
repeated
_ combination (22) -
repeated
_ permutation (22) -
report
_ on _ exception= (8) -
respond
_ to _ missing? (11) -
reverse
_ each (11) - rewind (11)
- rindex (22)
- rotate (11)
- rotate! (11)
- round (34)
- scan (22)
- select (55)
- select! (22)
- size (17)
-
slice
_ after (42) -
slice
_ before (55) -
slice
_ when (21) -
sort
_ by (11) -
sort
_ by! (11) -
source
_ location (33) - stat (11)
- status (11)
- step (90)
- strftime (11)
- sub (33)
- sub! (33)
- symlink? (11)
- sync= (11)
- take (11)
-
take
_ while (44) - terminate (11)
- then (6)
- times (11)
-
to
_ a (11) -
to
_ binary (9) -
to
_ enum (22) -
to
_ f (33) -
to
_ i (22) -
to
_ path (7) -
to
_ r (33) -
to
_ s (33) - tr (11)
- tr! (11)
-
tr
_ s (11) -
tr
_ s! (11) -
transform
_ keys (7) -
transform
_ keys! (7) -
transform
_ values (8) -
transform
_ values! (8) - truncate (55)
- tty? (11)
- unpack (11)
- unpack1 (8)
- update (22)
- upto (11)
-
values
_ at (44) - warn (3)
- with (2)
-
with
_ index (10) -
with
_ object (22) -
yield
_ self (7) - zip (22)
検索結果
先頭5件
-
Array
# at(nth) -> object | nil (15120.0) -
nth 番目の要素を返します。nth 番目の要素が存在しない時には nil を返します。
...nth 番目の要素を返します。nth 番目の要素が存在しない時には nil を返します。
@param nth インデックスを整数で指定します。
先頭の要素が 0 番目になります。nth の値が負の時には末尾から
のインデックス......。
整数以外のオブジェクトを指定した場合は to_int メソッドによる
暗黙の型変換を試みます。
@raise TypeError 引数に整数以外の(暗黙の型変換が行えない)オブジェクトを
指定した場合に発生しま... -
Array
# repeated _ combination(n) -> Enumerator (12321.0) -
サイズ n の重複組み合わせをすべて生成し、それを引数としてブロックを実行 します。
...生成する Enumerator オブジェクトを返します。
@param n 生成される配列のサイズを整数で指定します。
整数以外のオブジェクトを指定した場合は to_int メソッドによる暗
黙の型変換を試みます。
@raise TypeError 引......epeated_combination(1).to_a #=> [[1], [2], [3]]
a.repeated_combination(2).to_a #=> [[1,1],[1,2],[1,3],[2,2],[2,3],[3,3]]
a.repeated_combination(3).to_a #=> [[1,1,1],[1,1,2],[1,1,3],[1,2,2],[1,2,3],
# [1,3,3],[2,2,2],[2,2,3],[2,3,3],[3,3,3]]
a.repeated_combinatio......3,3]]
a.repeated_combination(0).to_a #=> [[]] # one combination of length 0
//}
ブロックが与えられた場合、作成した配列の各要素を引数としてブロックを実
行して self を返します。
//emlist[例][ruby]{
a = [1, 2, 3]
result = []
a.repeated_combination(3) {|e|... -
Array
# repeated _ permutation(n) -> Enumerator (12321.0) -
サイズ n の重複順列をすべて生成し,それを引数としてブロックを実行します。
...を生成する Enumerator オブジェクトを返します。
@param n 生成する配列のサイズを整数で指定します。
整数以外のオブジェクトを指定した場合は to_int メソッドによる暗
黙の型変換を試みます。
@raise TypeError 引......eated_permutation(1).to_a #=> [[1], [2]]
a.repeated_permutation(2).to_a #=> [[1,1],[1,2],[2,1],[2,2]]
a.repeated_permutation(3).to_a #=> [[1,1,1],[1,1,2],[1,2,1],[1,2,2],
# [2,1,1],[2,1,2],[2,2,1],[2,2,2]]
a.repeated_permutation(0).to_a #=> [[]] # one permutati......ロックを実
行して self を返します。
//emlist[例][ruby]{
a = [1, 2]
result = []
a.repeated_permutation(3) {|e| result << e} # => [1,2]
result #=> [[1,1,1],[1,1,2],[1,2,1],[1,2,2],
# [2,1,1],[2,1,2],[2,2,1],[2,2,2]]
//}
@see Array#repeated_combination, Array#permutation... -
Array
# repeated _ combination(n) { |c| . . . } -> self (12221.0) -
サイズ n の重複組み合わせをすべて生成し、それを引数としてブロックを実行 します。
...生成する Enumerator オブジェクトを返します。
@param n 生成される配列のサイズを整数で指定します。
整数以外のオブジェクトを指定した場合は to_int メソッドによる暗
黙の型変換を試みます。
@raise TypeError 引......epeated_combination(1).to_a #=> [[1], [2], [3]]
a.repeated_combination(2).to_a #=> [[1,1],[1,2],[1,3],[2,2],[2,3],[3,3]]
a.repeated_combination(3).to_a #=> [[1,1,1],[1,1,2],[1,1,3],[1,2,2],[1,2,3],
# [1,3,3],[2,2,2],[2,2,3],[2,3,3],[3,3,3]]
a.repeated_combinatio......3,3]]
a.repeated_combination(0).to_a #=> [[]] # one combination of length 0
//}
ブロックが与えられた場合、作成した配列の各要素を引数としてブロックを実
行して self を返します。
//emlist[例][ruby]{
a = [1, 2, 3]
result = []
a.repeated_combination(3) {|e|... -
Array
# repeated _ permutation(n) { |p| . . . } -> self (12221.0) -
サイズ n の重複順列をすべて生成し,それを引数としてブロックを実行します。
...を生成する Enumerator オブジェクトを返します。
@param n 生成する配列のサイズを整数で指定します。
整数以外のオブジェクトを指定した場合は to_int メソッドによる暗
黙の型変換を試みます。
@raise TypeError 引......eated_permutation(1).to_a #=> [[1], [2]]
a.repeated_permutation(2).to_a #=> [[1,1],[1,2],[2,1],[2,2]]
a.repeated_permutation(3).to_a #=> [[1,1,1],[1,1,2],[1,2,1],[1,2,2],
# [2,1,1],[2,1,2],[2,2,1],[2,2,2]]
a.repeated_permutation(0).to_a #=> [[]] # one permutati......ロックを実
行して self を返します。
//emlist[例][ruby]{
a = [1, 2]
result = []
a.repeated_permutation(3) {|e| result << e} # => [1,2]
result #=> [[1,1,1],[1,1,2],[1,2,1],[1,2,2],
# [2,1,1],[2,1,2],[2,2,1],[2,2,2]]
//}
@see Array#repeated_combination, Array#permutation... -
MatchData
# values _ at(*index) -> [String] (12146.0) -
正規表現中の n 番目の括弧にマッチした部分文字列の配列を返します。
...列全体を表します。
@param index インデックスを整数またはシンボル(名前付きキャプチャの場合)で 0 個以上指定します。
//emlist[例][ruby]{
m = /(foo)(bar)(baz)/.match("foobarbaz")
# same as m.to_a.values_at(...)
p m.values_at(0, 1, 2, 3, 4) # => ["fo......z", "foo", "bar", "baz", nil]
p m.values_at(-1, -2, -3, -4, -5) # => ["baz", "bar", "foo", nil, nil]
m = /(?<a>\d+) *(?<op>[+\-*\/]) *(?<b>\d+)/.match("1 + 2")
m.to_a # => ["1 + 2", "1", "+", "2"]
m.values_at(:a, :b, :op) # => ["1", "2", "+"]
//}
@see Array#values_at, Array#[]... -
MatchData
# post _ match -> String (12109.0) -
マッチした部分より後ろの文字列を返します($'と同じ)。
...マッチした部分より後ろの文字列を返します($'と同じ)。
//emlist[例][ruby]{
/(bar)(BAZ)?/ =~ "foobarbaz"
p $~.post_match # => "baz"
//}
@see MatchData#pre_match... -
MatchData
# pre _ match -> String (12109.0) -
マッチした部分より前の文字列を返します($`と同じ)。
...マッチした部分より前の文字列を返します($`と同じ)。
//emlist[例][ruby]{
/(bar)(BAZ)?/ =~ "foobarbaz"
p $~.pre_match # => "foo"
//}
@see MatchData#post_match... -
Enumerator
:: Lazy # collect _ concat {|item| . . . } -> Enumerator :: Lazy (9215.0) -
ブロックの実行結果をひとつに繋げたものに対してイテレートするような Enumerator::Lazy のインスタンスを返します。
...ロックの実行結果をひとつに繋げたものに対してイテレートするような
Enumerator::Lazy のインスタンスを返します。
//emlist[][ruby]{
["foo", "bar"].lazy.flat_map {|i| i.each_char.lazy}.force
#=> ["f", "o", "o", "b", "a", "r"]
//}
ブロックの返した値 x......umerator::Lazy) とき
それ以外のときは、x は分解されず、そのままの値として使われます。
//emlist[][ruby]{
[{a:1}, {b:2}].lazy.flat_map {|i| i}.force
#=> [{:a=>1}, {:b=>2}]
//}
@raise ArgumentError ブロックを指定しなかった場合に発生します。
@see......Enumerable#flat_map... -
Enumerator
:: Lazy # flat _ map {|item| . . . } -> Enumerator :: Lazy (9215.0) -
ブロックの実行結果をひとつに繋げたものに対してイテレートするような Enumerator::Lazy のインスタンスを返します。
...ロックの実行結果をひとつに繋げたものに対してイテレートするような
Enumerator::Lazy のインスタンスを返します。
//emlist[][ruby]{
["foo", "bar"].lazy.flat_map {|i| i.each_char.lazy}.force
#=> ["f", "o", "o", "b", "a", "r"]
//}
ブロックの返した値 x......umerator::Lazy) とき
それ以外のときは、x は分解されず、そのままの値として使われます。
//emlist[][ruby]{
[{a:1}, {b:2}].lazy.flat_map {|i| i}.force
#=> [{:a=>1}, {:b=>2}]
//}
@raise ArgumentError ブロックを指定しなかった場合に発生します。
@see......Enumerable#flat_map...