Re: TIB: Re: need help with high score


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

Re: TIB: Re: need help with high score




What you'll need to do is store your high score in a list.  The problem with
variables, as you've discovered, is that if you try to reference one that
doesn't exist, it gives you an error.  This isn't the case on the TI-82/83 for
example.  But with lists, you can dimension a list of n elements by using this
command:

n->dimL list_name

where n is the # of elements in the list, -> is the store symbol, and list_name
is the name of the list you want.  You can find the dimL command in the lists
menu (2nd minus sign) under ops (F4), it should be the first one there.  All
elements are initialized to zero if they don't already exist.  If the list
already exists, then it won't change the values already in the list, which is
good for keeping a high score. :)

To store a value in the list, say of 3 elements, you can do this:

{3,4,5}->list_name

or just

{400}->list_name

for a single value.  Note the curly braces.  Then to reference the value in the
list, to display the high score for example, simple use this:

list_name(1)

where 1 is the # of the element of the list you want.  Check pages 152-160 in
the manual for more info.

Hope this helps...

Bryan

----- Original Message -----
From: <IMY0URPA1N@aol.com>
To: <ti-basic@lists.ticalc.org>
Sent: Thursday, January 13, 2000 1:48 PM
Subject: Re: TIB: Re: need help with high score


>
> ti-86. if you want a copy of it right now i can send it to you so you can
> maybe figure some thing out
>
>



References: