N-Queens on 50g (RPL language)
|
11-21-2014, 04:27 PM
Post: #18
|
|||
|
|||
RE: N-Queens on 50g (RPL language)
Easy solution: replace n=10*k and work with the integers divided by 10, then compensate with the numeric factor, and no more integers anywhere:
Code:
The exact result is: 1 followed by 'x' 9's, then an 8, followed by 'x' 0's, then repeats the sequence with a 1 followed by... 'x' is the exponent of the end of the loop. If the loop starts from 1e3, there's 3 9's and 3 zeroes: 1.999 8 000 1 999 8 000 1 999 8 000 1 999 8 000 ... So it's easy to check for rounding errors even at higher precisions (which I want to benchmark too). |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)