[OT] fastest fibbonacci
Era Scarecrow via Digitalmars-d
digitalmars-d at puremagic.com
Tue Oct 25 00:05:20 PDT 2016
On Monday, 24 October 2016 at 19:03:51 UTC, Era Scarecrow wrote:
> It's only good through 71 iterations (longs) then it starts
> having errors. Also for some odd reason the input is one off,
> so I had to add a -1 to the input for it to align. This makes
> it accurate to 41/64 bit results.
>
> 71: 308061521170129 308061521170129 true
> 72: 498454011879264 498454011879265 false
Hmm as an experiment I changed from doubles to reals, and got a
slightly higher result, up to 85 giving us a 58/64
83: 99194853094755497 99194853094755497 true
84: 160500643816367088 160500643816367088 true
85: 259695496911122585 259695496911122585 true
86: 420196140727489673 420196140727489674 false
87: 679891637638612258 679891637638612259 false
88: 1100087778366101931 1100087778366101933 false
More information about the Digitalmars-d
mailing list