Class: Fixnum

Class | Fixnum
In: | rational.rb
Parent: | Object

### Methods

** quo rdiv rpower

### External Aliases

** | -> | power!

### Public Instance methods

**(other)

Alias for rpower

quo(other)

If Rational is defined, returns a Rational number instead of a Fixnum.

[Source]

    # File rational.rb, line 508
      def quo(other)
        Rational.new!(self,1) / other
      end

rdiv(other)

Alias for quo

rpower(other)

Returns a Rational number if the result is in fact rational (i.e. `other` < 0).

[Source]

    # File rational.rb, line 514
      def rpower (other)
        if other >= 0
          self.power!(other)
        else
          Rational.new!(self,1)**other
        end
      end

[Validate]