This is documentation for Mathematica 8, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.2)

IntegerExponent

IntegerExponent
gives the highest power of b that divides n.
  • Integer mathematical function, suitable for both symbolic and numerical manipulation.
  • IntegerExponent gives the number of trailing zeros in the digits of n in base b.
The number of trailing zeros:
The highest power of 2:
Plot it:
The number of trailing zeros:
In[1]:=
Click for copyable input
Out[1]=
 
The highest power of 2:
In[1]:=
Click for copyable input
Out[1]=
In[2]:=
Click for copyable input
Out[2]=
 
Plot it:
In[1]:=
Click for copyable input
Out[1]=
Number of trailing zeros in factorials:
Powers of 2 in successive integers:
Find the highest power of 2 that appears in the factors of a number:
A "formula" for DigitCount:
New in 4