るりまサーチ (Ruby 2.7.0)

最速Rubyリファレンスマニュアル検索!
2件ヒット [1-2件を表示] (0.079秒)
トップページ > クラス:Numeric[x] > クエリ:_builtin[x] > クエリ:numeric[x] > ライブラリ:ビルトイン[x] > クエリ:rect[x] > バージョン:2.7.0[x]

別のキーワード

  1. _builtin new
  2. _builtin inspect
  3. _builtin []
  4. _builtin to_s
  5. _builtin each

検索結果

Numeric#rect -> [Numeric, Numeric] (106033.0)

[self, 0] を返します。

...[self, 0] を返します。

//emlist[例][ruby]{
1.rect # => [1, 0]
-1.rect # => [-1, 0]
1.0.rect # => [1.0, 0]
-1.0.rect # => [-1.0, 0]
//}

Numeric
のサブクラスは、このメソッドを適切に再定義しなければなりません。

@see Complex#rect...

Numeric#rectangular -> [Numeric, Numeric] (70033.0)

[self, 0] を返します。

...[self, 0] を返します。

//emlist[例][ruby]{
1.rect # => [1, 0]
-1.rect # => [-1, 0]
1.0.rect # => [1.0, 0]
-1.0.rect # => [-1.0, 0]
//}

Numeric
のサブクラスは、このメソッドを適切に再定義しなければなりません。

@see Complex#rect...