るりまサーチ

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

関連するキーワード

  1. rational **
  2. rational quo
  3. rational power!
  4. ** rational
  5. rational rational

ライブラリ

キーワード

検索結果

Fixnum#**(other) -> Integer | Float | Rational (125)

冪(べき)乗を計算します。other が 0 以下の場合、計算結果を Rational オブジェクトで返します。

...)乗を計算します。other が 0 以下の場合、計算結果を
Rational
オブジェクトで返します。

@param other 自身を other 乗する数

2.rpower(3) # => 8
2.rpower(-3) # => Rational(1, 8)...

Fixnum#rpower(other) -> Integer | Float | Rational (125)

冪(べき)乗を計算します。other が 0 以下の場合、計算結果を Rational オブジェクトで返します。

...)乗を計算します。other が 0 以下の場合、計算結果を
Rational
オブジェクトで返します。

@param other 自身を other 乗する数

2.rpower(3) # => 8
2.rpower(-3) # => Rational(1, 8)...

Fixnum#quo(other) -> Rational (124)

商を計算して計算結果を Rational オブジェクトで返します。

...商を計算して計算結果を Rational オブジェクトで返します。

@param other 自身を割る数

例:

1.quo(2) # => Rational(1,2)...

Fixnum#power!(other) -> Integer | Float (7)

冪(べき)乗を計算します。

...冪(べき)乗を計算します。

@param other 自身を other 乗する数

rational
で再定義される前のFixnum#**の別名です。
other が正または 0 の整数 (Integer) ならば、整数 (Integer) を、それ以外
なら、浮動小数 (Float) を返します。...