[REBOL] Re: SKIP with *very* large values
From: carl:cybercraft at: 16-May-2002 21:27
On 16-May-02, Gregg Irwin wrote:
> OK, I'm not expecting to ever need the use values this large with
> SKIP, but I'm a little puzzled by the behavior.
>>> skip [1 2 3] 99999999999999999999
> == []
>>> skip [1 2 3] 999999999999999999999
> == [1 2 3]
>>> skip [1 2 3] -99999999999999999
> == [1 2 3]
>>> skip [1 2 3] -999999999999999999
> == []
>>> skip [1 2 3] -9999999999999999999
> == []
>>> skip [1 2 3] -99999999999999999999
> == []
>>> skip [1 2 3] -999999999999999999999
> == [1 2 3]
> Any thoughts?
I'd think it's due to the maths routines your OS uses, as on Amiga I
don't get the results you get, the positive numbers all returning an
empty block and the negative ones a full one. What do you get when
you enter just the numbers at the Console? ie...
>> 99999999999999999999
== 1E+20
>> 999999999999999999999
== 1E+21
>> -99999999999999999
== -1E+17
>> -999999999999999999
== -1E+18
--
Carl Read