Functions similar to randomize()

Started by boral, July 23, 2013, 04:06:40 PM

Previous topic - Next topic

boral

Pelles C does not support randomize() . Is there any function which is alternative to randomize() and is supported by Pelles C ?

frankie

randomize() is BASIC.
Open help and search for rand() function.
"It is better to be hated for what you are than to be loved for what you are not." - Andre Gide

boral

Quote from: frankie on July 23, 2013, 05:57:29 PM
randomize() is BASIC.
Open help and search for rand() function.
Thanks for your reply. Can you please explain in brief how does the 'seed' works ? Thanks in advance.

Bitbeisser

Quote from: boral on July 23, 2013, 06:10:19 PM
Quote from: frankie on July 23, 2013, 05:57:29 PM
randomize() is BASIC.
Open help and search for rand() function.
Thanks for your reply. Can you please explain in brief how does the 'seed' works ? Thanks in advance.
Well, you might better ask what part of the (pseudo)random number generation is unclear to you.

The 'seed' is a random (or not) starting value from which the (pseudo)random number generator starts to generate it's output. The same seed will result in the same sequence of generated numbers. Different seeds will result in different number sequences.

Ralf

Miki

I found some ANSI C source code for a random number generator library.

http://www.cs.wm.edu/~va/software/park/

I hope this helps.

:Miki.