Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #92291

Re: Python Random vs. Cython C Rand for Dice Rolls

Date 2015-06-07 11:56 -0700
From "C.D. Reimer" <chris@cdreimer.com>
Subject Re: Python Random vs. Cython C Rand for Dice Rolls
References <mailman.262.1433697446.13271.python-list@python.org> <55748e6d$0$13008$c3e8da3$5496439d@news.astraweb.com>
Newsgroups comp.lang.python
Message-ID <mailman.273.1433703386.13271.python-list@python.org> (permalink)

Show all headers | View raw


On 6/7/2015 11:33 AM, Steven D'Aprano wrote:
> C rand is not even close to random. The technical term for it is "shite".

Looking through the BASIC book, I remembered all the tricks needed to 
get a half-way decent number generator on a 1MHz processor back in the 
day. Either the numbers start repeating after a while or get stuck on a 
particular number. That's one of the challenges of converting these old 
games from BASIC to Python. A lot of the stuff done in BASIC was meant 
to get around the hardware limitations of the early computers.

Chris R.

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Python Random vs. Cython C Rand for Dice Rolls "C.D. Reimer" <chris@cdreimer.com> - 2015-06-07 10:17 -0700
  Re: Python Random vs. Cython C Rand for Dice Rolls Steven D'Aprano <steve@pearwood.info> - 2015-06-08 04:33 +1000
    Re: Python Random vs. Cython C Rand for Dice Rolls "C.D. Reimer" <chris@cdreimer.com> - 2015-06-07 11:56 -0700
    Re: Python Random vs. Cython C Rand for Dice Rolls Laura Creighton <lac@openend.se> - 2015-06-08 19:33 +0200
    Re: Python Random vs. Cython C Rand for Dice Rolls Sturla Molden <sturla.molden@gmail.com> - 2015-06-08 23:44 +0200

csiph-web