Re: TIB: Help quick! 82 to 83 conversion trouble


[Prev][Next][Index][Thread]

Re: TIB: Help quick! 82 to 83 conversion trouble




On Thu, 27 May 1999 16:04:26 -0400, Vimm wrote:

>
>I have a problem that I really need solved tonight.  I've spent the past
>couple of weeks writing a game for a classmate who has a TI-83, so I
>decided to write it in Basic since I have an 82.  I finally finished it
>last night and when I gave it to him today it produced an error.  I
>spent a few minutes looking at the code and couldn't find anything
>wrong.  On top of that I'm graduating tomorrow and probably will never
>have another chance to givce it to him after tomorrow, so I need to fix
>it before then!  Can anyone help me out?  Here's the TI-82 code.  It's
>supposed to generate 52 numbers in L4 and then randomly move them to
>L5.  It works fine on my TI-82 but seems to suffer in the translation.
>
>This is the TI-82 code...
>(Generates 13 sets of 4 numbers 3-15 in list 4 (ex. 3,3,3,3,4,4,4,4,
>etc.))
>:52->dim L4
>:52->dim L5
>:For(A,0,12
>:For(Z,1,4
>:A+3->L4(4A+Z
>:End
>:End
>(The part above seems to work fine)
>(Randomly moves all numbers in L4 to L5)
>:For(A,1,52
>:int rand(53-A)+1->Z
>:L4(Z)->L5(A
>:0->L4(Z
>:SortD(L4
>:52-A->dim L4
>:End
>
>Hmm...Cut and paste didn't work.  I edited it to make it understandable.
>
>(Substituted -> for store command)
>The command that generates the random number isn't working right on the
>TI-83.
>I noticed the int command on the 83 is int(.  Do I need another
>parenthesi or something?  It's not randomly generating a number on the
>83.  Can someone please help me out?  I don't have a TI-83 so I don't
>know how to fix it!  I want to be able to send from my TI-82 to an 83
>and have it work on both.  Can anyone help?  Please!  I don't want all
>of my work to go to waste over this one little error....
>
>Vimm
>

If you think you're having trouble with the int command, try this:

int(rand(53-A)+1)->Z

I can't see why this won't work, but tell me if it doesn't.

James Vernon
jimbob_v@hotmail.com


______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com


Follow-Ups: