るりまサーチ

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

別のキーワード

  1. socket int
  2. prime int_from_prime_division
  3. _builtin to_int
  4. mkmf convertible_int
  5. option int

キーワード

検索結果

<< 1 2 3 ... > >>

Matrix#tr -> Integer | Float | Rational | Complex (21202.0)

トレース (trace) を返します。

...トレース (trace) を返します。

行列のトレース (trace) とは、対角要素の和です。

//emlist[例][ruby]{
require 'matrix'
Matrix[[7,6], [3,9]].trace # => 16
//}

tr
ace は正方行列でのみ定義されます。

@raise ExceptionForMatrix::ErrDimensionMismatch 行列が...

TracePoint#instruction_sequence -> RubyVM::InstructionSequence (12201.0)

script_compiledイベント発生時にコンパイルされた RubyVM::InstructionSequenceインスタンスを返します。

..._compiledイベント発生時にコンパイルされた
RubyVM::InstructionSequenceインスタンスを返します。

//emlist[例][ruby]{
Tr
acePoint.new(:script_compiled) do |tp|
p tp.instruction_sequence # => <RubyVM::InstructionSequence:block in <main>@(eval):1>
end.enable do
eval("puts...

Matrix#trace -> Integer | Float | Rational | Complex (9202.0)

トレース (trace) を返します。

...トレース (trace) を返します。

行列のトレース (trace) とは、対角要素の和です。

//emlist[例][ruby]{
require 'matrix'
Matrix[[7,6], [3,9]].trace # => 16
//}

tr
ace は正方行列でのみ定義されます。

@raise ExceptionForMatrix::ErrDimensionMismatch 行列が...

Fiddle::CStruct#to_ptr -> Fiddle::Pointer (9201.0)

保持している構造体へのポインタを返します。

保持している構造体へのポインタを返します。

Fiddle::Pointer#to_str -> String (9201.0)

自身が指す領域から長さ len の文字列を複製して返します。

自身が指す領域から長さ len の文字列を複製して返します。

len を省略した場合は、self.size をその代わりに使います。

@param len 文字列の長さを整数で指定します。

絞り込み条件を変える

Fiddle::Pointer#to_str(len) -> String (9201.0)

自身が指す領域から長さ len の文字列を複製して返します。

自身が指す領域から長さ len の文字列を複製して返します。

len を省略した場合は、self.size をその代わりに使います。

@param len 文字列の長さを整数で指定します。

Integer#integer? -> true (9201.0)

常に真を返します。

...常に真を返します。

//emlist[][ruby]{
1.integer? # => true
1.0.integer? # => false
//}...

Integer#truncate(ndigits = 0) -> Integer (9201.0)

0 から self までの整数で、自身にもっとも近い整数を返します。

...します。
負の整数を指定した場合、小数点位置から左に少なくとも n 個の 0 が並びます。

//emlist[][ruby]{
1.truncate # => 1
1.truncate(2) # => 1
18.truncate(-1) # => 10
(-18).truncate(-1) # => -10
//}

@see Numeric#truncate...

Integer#truncate(ndigits = 0) -> Integer | Float (9201.0)

0 から self までの整数で、自身にもっとも近い整数を返します。

...定した場合、Integer を返します。
小数点位置から左に少なくとも n 個の 0 が並びます。

//emlist[][ruby]{
1.truncate # => 1
1.truncate(2) # => 1.0
18.truncate(-1) # => 10
(-18).truncate(-1) # => -10
//}

@see Numeric#truncate...

String#codepoints -> [Integer] (9201.0)

文字列の各コードポイントの配列を返します。(self.each_codepoint.to_a と同じです)

...列を返します。(self.each_codepoint.to_a と同じです)

//emlist[例][ruby]{
#coding:UTF-8
"hello わーるど".codepoints
# => [104, 101, 108, 108, 111, 32, 12431, 12540, 12427, 12393]
//}

ブロックが指定された場合は String#each_codepoint と同じように動作します。...
...Ruby 2.6 までは deprecated の警告が出ますが、Ruby 2.7 で警告は削除されました。

@see String#each_codepoint...

絞り込み条件を変える

String#codepoints {|codepoint| block } -> self (9201.0)

文字列の各コードポイントの配列を返します。(self.each_codepoint.to_a と同じです)

...列を返します。(self.each_codepoint.to_a と同じです)

//emlist[例][ruby]{
#coding:UTF-8
"hello わーるど".codepoints
# => [104, 101, 108, 108, 111, 32, 12431, 12540, 12427, 12393]
//}

ブロックが指定された場合は String#each_codepoint と同じように動作します。...
...Ruby 2.6 までは deprecated の警告が出ますが、Ruby 2.7 で警告は削除されました。

@see String#each_codepoint...
<< 1 2 3 ... > >>