Re: A89: Random number help
[Prev][Next][Index][Thread]
Re: A89: Random number help
You can userlib::random
Here is an example.
you can write your question before this and this will
send you randomly to an answer.
move.w #14,d0 ;uperlimit of random number
jsr userlib::random :put's a random number 0<x<14
in d0.
cmp.w #0,d0 ; 0 is lowest number that can be gotten
beq answer1 ; branches to answer one.
cmp.w #1,d0 ; check to see if one
beq answer2 ; goes to answer two.
And so on until it is 14. I hope this helps.
--- Jer2665@aol.com wrote:
>
> ok, i put out a message a little while ago that no
> one responded to so im
> gonna ask again. im looking for someone to help me
> out with random numbers.
> i want the program to go to a different program and
> get like a random number
> from 1-15, or something, and with that number go
> through and get that list.
> such that
>
> Randint(1,15,Num)
> If Num=1
> Then
> "why does no one in this list ever answer my
> questions?"->question
> "Because no one knows the answer."->answer1
> "because they are too lazy to type"->answer2
> "no one feels like helping"->answer3
> return
> if Num=2
> Then
> ...
> etc, etc
>
> understand what im asking for? please help this
> time. thanks
>
>
>
===
Visit my website, Some Assembly Required, at
http://meltingpot.fortunecity.com/gilford/908
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com