in reply to Strange Logic in Power of arithmetic

Active State 5.8.8 on Win64

line 1: -8 line 2: -1.#IND line 3: Illegal division by zero at -e line 1 line 4: -2147483645

Had to do each one line by line as it failed as a script on line 3 otherwise

version 5.6.1 on Solars

line 1: -8 line 2: NaN line 3: NaN line 4: NaN

If I type them in on Windows as perl -e "print -4**1.5;"..., I get

-8 -4 Illegal division by zero at -e line 1 -2147483645

Replies are listed 'Best First'.
Re^2: Strange Logic in Power of arithmetic
by 1nickt (Canon) on Jan 12, 2016 at 16:03 UTC
    Active State 5.8.8 on Win64 line 1: -8 line 2: -1.#IND line 3: Illegal division by zero at -e line 1 line 4: -2147483645
    Interesting. Not on darwin:
    $ perlbrew exec perl 1152551.pl perl-5.8.8 ========== Power of calculation test line 1: -8 line 2: nan line 3: nan line 4: nan
    The way forward always starts with a minimal test.

      Win 7 64 bit, ActiveState 5.8.8 built for MSWin32-x86-multithread Binary build 817