Ruby/Справочник/Integer: различия между версиями

Содержимое удалено Содержимое добавлено
Строка 95:
<source lang=ruby>num.lcm(other) #-> integer</source>
----
Возвращает [[w:НОК|наименьшее общее кратное]] двух чисел (''num'' и ''other'').
Returns the <i>lowest common multiple</i> (LCM) of the two arguments (<tt>self</tt> and <tt>other</tt>).
<source lang=ruby>6.lcm 7 #-> 42
6.lcm 9 #-> 18</source>
 
===Integer#next===
----