Re: TIB: Double IF statement Question
[Prev][Next][Index][Thread]
Re: TIB: Double IF statement Question
mr. universe wrote:
>
> If A==1 AND B==2
> like that?
>
> On Tue, 20 Jan 1998, Jump Off Productions Inc. wrote:
> >
> > Hey,
> > I was wondering if there is any way to have a double if statement?
If that was what you were wondering about, then here's a little
addition. This can be shortened because of the way the calculator
reads logic statements. It only treats things as 1 (true) or 0
(false). What this means is this; :If 1 will ALWAYS be true and the
calc will ALWAYS execute the next line, or If 0 will ALWAYS be false
and the calc will NEVER execute the next line. Using the same logic,
if you wanted a line to be; If N<>0, then you could also just put; If
N. Because an and statement requires BOTH to be true, it is the same
as multiplication. ie. If A<>0 and B<>0 is the same as If AB. For a
much better explaination I recommend going to the TI-Philes BASIC
columns and reading the 3 articles titled "Advanced TI-82 Programming"
by Frank Force. VERY good explaination.
Jody Snider
jody1@alaska.net
References: