Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / RND() doesnt create random numbers

Author
Message
Vandetta
21
Years of Service
User Offline
Joined: 17th Dec 2002
Location:
Posted: 22nd Dec 2002 02:44
run this little program:

a=rnd(10)
b=rnd(10)
c=rnd(10)
print a
print b
print c
wait key

you get the same results for a, b, and c everytime whats up?
Easily Confused
21
Years of Service
User Offline
Joined: 22nd Oct 2002
Location: U.K. Earth. (turn right at Venus)
Posted: 22nd Dec 2002 02:57
Are you using Randomize Timer() at the top of your program?

"Earth is the cradle of humanity,
but one cannot live in a cradle forever"
Konstantin E. Tsiolkovsky (1911)
Vandetta
21
Years of Service
User Offline
Joined: 17th Dec 2002
Location:
Posted: 22nd Dec 2002 03:13
nope, thanks.

Login to post a reply

Server time is: 2024-05-05 07:49:15
Your offset time is: 2024-05-05 07:49:15