self ** other -> Fixnum | Bignum | Float[permalink][rdoc]-
算術演算子。冪(べき乗)を計算します。
- [PARAM] other:
- 二項演算の右側の引数(対象)
- [RETURN]
- 計算結果
2 ** 3 # => 8 2 ** 0 # => 1 0 ** 0 # => 1
self ** other -> Integer | Float | Rational[permalink][rdoc] [redefined by rational]rpower(other) -> Integer | Float | Rational[redefined by rational]-
冪(べき)乗を計算します。other が負の整数の場合、計算結果を Rational オブジェクトで返します。
(1<<32).rpower(2) # => 18446744073709551616 (1<<32).rpower(-2) # => Rational(1, 18446744073709551616)
- [PARAM] other:
- 自身を other 乗する数