Ruby 1.9.0 リファレンスマニュアル > ライブラリ一覧 > library mathn > class Integer > gcd2
gcd2(int)
self と int の最大公約数を求めます。
例:
12.gcd2 8 # => 4