home *** CD-ROM | disk | FTP | other *** search
- /*--------------------------------------*/
- /* */
- /* POWER(X,X) */
- /* */
- /* Functionality: */
- /* Exponential calculations. */
- /* Arguments: */
- /* 0: The base number */
- /* 1: The mantissa */
- /* Returns: An integer result of the */
- /* calculation. */
- /* Author: John Callicotte */
- /* Date created/modified: 09/01/88 */
- /* */
- /*--------------------------------------*/
-
- power(a,b)
- int a,b;
- {
- int d,j;
- d=1;
- if (b){ /* Check for 0 mantissa. */
- for (j=0;j<b;j++)
- d*=a;
- }
- return(d);
- }