Next:
Integer-printing
, Previous:
Integer-iterators
, Up:
Integer
1.89.8 Integer: math methods
binomial: anInteger
Compute the number of combinations of anInteger objects among a number of objects given by the receiver.
ceilingLog: radix
Answer (self log: radix) ceiling. Optimized to answer an integer.
estimatedLog
Answer an estimate of (self abs floorLog: 10)
even
Return whether the receiver is even
factorial
Return the receiver's factorial.
floorLog: radix
Answer (self log: radix) floor. Optimized to answer an integer.
gcd: anInteger
Return the greatest common divisor (Euclid's algorithm) between the receiver and anInteger
lcm: anInteger
Return the least common multiple between the receiver and anInteger
odd
Return whether the receiver is odd