Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: 64-Bit random numbers

Author: Johan de Koning

Date: 22:54:23 11/02/03

Go up one level in this thread


On November 02, 2003 at 23:07:44, Robert Hyatt wrote:

>On November 02, 2003 at 22:14:22, Johan de Koning wrote:
>
>>On November 01, 2003 at 18:32:08, Robert Hyatt wrote:
>>
>>>On November 01, 2003 at 05:00:48, Johan de Koning wrote:
>>>
>>>>On October 31, 2003 at 10:27:00, Robert Hyatt wrote:
>>>>
>>>>>On October 31, 2003 at 01:36:17, Johan de Koning wrote:
>>>>>
>>>>>>On October 30, 2003 at 09:44:48, Robert Hyatt wrote:
>>>>>>
>>>>>>>On October 29, 2003 at 13:39:03, Vincent Diepeveen wrote:
>>>>>>
>>>>>>>>It's like saying using 'goto' is ok in a programming environment. Where this is
>>>>>>>>certainly true, it should not be a policy to do so :)
>>>>>>>
>>>>>>>Eh?  _every_ program you write has goto's.  (aka jumps).  They are not
>>>>>>>bad.  In fact, they are _unavoidable_.
>>>>>>
>>>>>>OT1: They *are* avoidable.
>>>>>>Any finite algorithm that does not depend on mid-execution input (typically
>>>>>>time) can be written as 1 single expression. It would of course be huge and
>>>>>>run rather slowly without quantum computing.
>>>>>
>>>>>I don't know how you can possibly encode a loop into a complex expression,
>>>>>not knowing beforehand how many loop iterations will be needed...
>>>>
>>>>By expanding all possibilities.
>>>
>>>What if you don't know how many possibilities there are. IE repetition
>>>checking.  Etc..
>>
>>If *all* possibilities is finite, you know how many.
>>
>>#define REP \
>>    (zob[0] == zob[-4]) \
>>  + (zob[0] == zob[-6]) \
>>  + (zob[0] == zob[-8]) etc
>
>OK.. I can see how it would work, but not as above.  Each zob[x] has
>to be protected by something like this:
>
>(moves_in_replist>=4) * (zob[0] == zob[-4])

If you can get a value for
  moves_in_replist
you can get a value for
  zob[-100], zob[-99], ...
just as well.

>However, most compilers will wreck there and crash the program.  IE
>it doesn't always work to do x[y-j] where j > y.  So the subscripts
>have to be done the same way...

More importantly,
most compilers will choke on expressions with, say, 10^15 operators. :-)

... Johan



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.