るりまサーチ

最速Rubyリファレンスマニュアル検索!
579件ヒット [1-100件を表示] (0.082秒)
トップページ > クエリ:n[x] > クエリ:abs[x]

別のキーワード

  1. etc sc_xopen_enh_i18n
  2. rsa n
  3. rsa n=
  4. pop n_mails
  5. pop n_bytes

検索結果

<< 1 2 3 ... > >>

NEWS for Ruby 3.0.0 (26006.0)

NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。

...NEWS for Ruby 3.0.0
このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。

それぞれのエントリーは参照情報があるため短いです。
十分な情報と共に書かれた全ての変更のリス...
...ord arguments are now separated from positional arguments.
Code that resulted in deprecation warnings in Ruby 2.7 will now
result in ArgumentError or different behavior. 14183
* Procs accepting a single rest argument and keywords are no longer
subject to autosplatting. This now matche...
...ng a class and a object multiple times in a method when possible.
* Optimize accesses in some core classes like Hash and their subclasses.
* Method inlining support for some C methods
* `Kernel`: `#class`, `#frozen?`
* `Integer`: `#-@`, `#~`, `#abs`, `#bit_length`, `#even...

Bignum#abs -> Fixnum | Bignum (21301.0)

self の絶対値を返します。

self の絶対値を返します。

Fixnum#abs -> Fixnum | Bignum (21301.0)

self の絶対値を返します。

self の絶対値を返します。

Integer#abs -> Integer (21219.0)

self の絶対値を返します。

...self の絶対値を返します。

//emlist[][ruby]{
-12345.abs # => 12345
12345.abs # => 12345
-1234567890987654321.abs # => 1234567890987654321
//}...

Numeric#abs -> Numeric (21219.0)

自身の絶対値を返します。

...自身の絶対値を返します。

//emlist[例][ruby]{
12.abs #=> 12
(-34.56).abs #=> 34.56
-34.56.abs #=> 34.56
//}...

絞り込み条件を変える

Rational#abs -> Rational (21213.0)

自身の絶対値を返します。

...自身の絶対値を返します。

//emlist[例][ruby]{
Rational(1, 2).abs # => (1/2)
Rational(-1, 2).abs # => (1/2)
//}...

Complex#abs -> Numeric (18225.0)

自身の絶対値を返します。

...す。

以下の計算の結果を Float オブジェクトで返します。

sqrt(self.real ** 2 + self.imag ** 2)

//emlist[例][ruby]{
Complex(1, 2).abs # => 2.23606797749979
Complex(3, 4).abs # => 5.0
Complex('1/2', '1/2').abs # => 0.7071067811865476
//}

@see Complex#abs2...

RDoc::Text#expand_tabs(text) -> String (12200.0)

引数中のタブ(\t)を直前の連続するスペースと合計して 8 文字のスペースにな るように置き換えます。

引数中のタブ(\t)を直前の連続するスペースと合計して 8 文字のスペースにな
るように置き換えます。

@param text 文字列を指定します。

RDoc::TopLevel#file_absolute_name -> String (12200.0)

自身が管理するファイルに関する絶対パスを文字列で返します。

自身が管理するファイルに関する絶対パスを文字列で返します。

RDoc::TopLevel#file_absolute_name=(val) (12200.0)

自身が管理するファイルに関する絶対パスを文字列で設定します。

自身が管理するファイルに関する絶対パスを文字列で設定します。

@param val パスを文字列で指定します。

絞り込み条件を変える

RubyVM::InstructionSequence#absolute_path -> String | nil (12200.0)

self が表す命令シーケンスの絶対パスを返します。

...ら作成していた場合は nil を返します。

例1:irb で実行した場合

iseq = RubyVM::InstructionSequence.compile('num = 1 + 2')
# => <RubyVM::InstructionSequence:<compiled>@<compiled>>
iseq.absolute_path
# => nil

例2: RubyVM::InstructionSequence.compile_file を使用し...
...た場合

# /tmp/method.rb
def hello
puts "hello, world"
end

# irb
> iseq = RubyVM::InstructionSequence.compile_file('/tmp/method.rb')
> iseq.absolute_path # => "/tmp/method.rb"

@see RubyVM::InstructionSequence#path...
<< 1 2 3 ... > >>