Signature (Visual Basic / VBA)
Public Function LeastCommonMultiple( _
ByVal vX As Variant _
, ByVal vY As Variant _
) As Variant
Code Examples
LeastCommonMultiple(34, 12) = 204
LeastCommonMultiple(45, 67) = 3015
LeastCommonMultiple(34, 4192) = 71264
LeastCommonMultiple(12, 65) = 780
LeastCommonMultiple(12, 64) = 192
LeastCommonMultiple(123456789012345#, 12345678901234#) = 1.52415787532381E+27
Abs(X * Y) / GreatestCommonDivisor(X, Y)
Parameters
| Parameter | Description |
|---|---|
| vX | First of two numbers whose least common multiple is to be calculated. Function returns Null if vX is Null or cannot be fixed up to a number. |
| vY | Second of two numbers whose smallest common multiple is to be calculated. Function returns Null if vX is Null or cannot be fixed up to a number. |