Leading the way in Microsoft Office Development
 Home|Excel|Word|PowerPoint|Consultancy|Feedback|Contact 
 Microsoft Excel > Functions > Maths and Trigonometry > GCD

 

GCD(number1 [,number2] [, …])

 
 Returns the greatest common divisor of two or more integers.

 number1The first number.
 number2The second optional number.

 REMARKS
 
  • This function is only available if you have the Analysis ToolPak add-in installed.
     
  • The greatest common divisor is the largest integer that divides both "number1" and "number2" without a remainder.
     
  • If any of the arguments are not numeric, then #VALUE! is returned.
     
  • If any argument is less than zero, then #NUM! is returned.
     
  • One divides any value evenly ??
     
  • A prime number has only itself and one as even divisors.
     
  • You can have a maximum of 29 arguments.

     EXAMPLES
     
     A
    1=GCD(5,2) = 1
    2=GCD(1,50) = 1
    3=GCD(50,2) = 2
    4=GCD(24,36) = 12
    5=GCD(7,1) = 1
    6=GCD(5,0) = 5
    7=GCD(5,-0.5) = #NUM!
    8=GCD("some text",0.5) = #VALUE!
     

     Functions - G | Index - G | Office Online 

     Copyright © 2004-2007 Better Solutions Limited. All Rights Reserved.Top