GCF ( A ; B )
Rate this function: Average rating: 5.0 (3 votes) Discuss this Custom Function
Scott Morrison, InDev
http://www.indev.ca
Greatest Common Factor of two numbers
Sample Input:
|
Sample Output:
|
Description:
Uses Euclid's method of recursively computing the GCF (the GCF of two numbers is the same as the GCF of the smaller and the remainder (modula) of the larger divided by the smaller; and by definition, the GCF of any number and 0 is the number)
Note that the lowest common multiple of two numbers is their product divided by their GCF. In otherwords:
LCM(A, B) = A * B / GCF(A,B)
Note: these functions are not guaranteed
or supported by BrianDunning.com. Please contact the individual
developer with any questions or problems.
This is my Custom Function and I want to
edit it
Discuss:There are no comments yet. Be the first to post a comment about this Custom Function! Please try to keep it brief & to the point. Anyone can post:
|
Newest Custom Functions:
| 1. |
GetAge ( birthdate ) |
| |
(Fri, Jul 03, 8:14pm) |
| 2. |
captialLetters ( numWords ; text) |
| |
(Thu, Jul 02, 9:53am) |
| 3. |
Base64ToAscII ( string ) |
| |
(Sun, Jun 28, 11:47am) |
| 4. |
AscIIToBase64 (string) |
| |
(Sun, Jun 28, 11:36am) |
| 5. |
ToggleFlag_cf ( myfield ; myVL ; pos ; neg ) |
| |
(Fri, Jun 26, 12:41pm) |
| 6. |
IsDaylightSavings ( TS ) |
| |
(Thu, Jun 18, 1:56pm) |
| 7. |
DaylightSavingsEnds |
| |
(Thu, Jun 18, 1:38pm) |
| 8. |
DaylightSavingsBegins |
| |
(Thu, Jun 18, 1:35pm) |
 |
|