# to the nth power

Mark W. Schumann catfood at NCoast.ORG
Sun Nov 4 07:43:27 AEST 1990


In article <ENAG.90Nov3145415 at hild.ifi.uio.no> enag at ifi.uio.no (Erik Naggum) writes:
>In article <1990Nov2.182217.13958 at NCoast.ORG> catfood at NCoast.ORG (Mark W. Schumann) writes:
>
>   Spiffy, but it does depend on (exponent & 1) being the same as saying
>   "exponent is odd."  Most implementations support this, though.
>   Again, neither solution supports negative exponents.
>
>Which are the implementations that doesn't?

There may be none.  You are simply not allowed to assume *anything*
about the internal representation of integers if your programs are to
be 100% portable ANSI.  I realize this is an extremely conservative
application of the principle, but "all the machines we know about"
is not the same as "all the machines that could ever possibly be."

-- 
============================================================
Mark W. Schumann  3111 Mapledale Avenue, Cleveland 44109 USA
Domain: catfood at ncoast.org
UUCP:   ...!mailrus!usenet.ins.cwru.edu!ncoast!catfood
============================================================



More information about the Comp.lang.c mailing list