Type:
Class

Bignum objects hold integers outside the range of Fixnum. Bignum objects are created automatically when integer calculations would otherwise overflow a Fixnum. When a calculation involving Bignum objects returns a result that will fit in a Fixnum, the result is automatically converted.

For the purposes of the bitwise operations and [], a Bignum is treated as if it were an infinite-length bitstring with 2's complement representation.

While Fixnum values are immediate, Bignum objects are not—assignment and parameter passing work with references to objects, not the objects themselves.

When mathn is required Bignum's division and exponentiation are enhanced to return more precise values from mathematical expressions.

*

big * other â Numeric Instance Public methods Multiplies big and other, returning

2015-03-31 10:30:37
~

~big â integer Instance Public methods Inverts the bits in big. As Bignums

2015-03-31 12:57:24
divmod

big.divmod(numeric) â array Instance Public methods See Numeric#divmod

2015-03-31 11:54:02
[]

big[n] â 0, 1 Instance Public methods Bit ReferenceâReturns the nth

2015-03-31 11:28:41
size

big.size â integer Instance Public methods Returns the number of bytes in the

2015-03-31 12:43:43
to_f

big.to_f â float Instance Public methods Converts big to a Float

2015-03-31 12:49:57
===

big == obj â true or false Instance Public methods Returns true

2015-03-31 11:13:32
div

big.div(other) â integer Instance Public methods Performs integer division:

2015-03-31 11:47:24
|

big | numeric â integer Instance Public methods Performs bitwise or

2015-03-31 12:55:04
>

big > real â true or false Instance Public methods Returns true

2015-03-31 11:16:41