Re: TIB: program speed
[Prev][Next][Index][Thread]
Re: TIB: program speed
Jared Ivey wrote:
>
> Jody <jody1@alaska.net> writes:
> >>Jeremy Braun wrote:
> [snip]
> >So, if I'm getting this right, you're
> >saying that it is FASTER to do
> >:If C=2
> >:Q+1->Q (or Q/5->Q or whatever)
> >
> >and it is SLOWER to do
> >:Q+(C=2->Q
> >
> >Do I got it right?
>
> No that is incorrect, at least for my TI-85.
> The If statement was always slower and bigger.
> The true statements were always faster.
>
> A monospaced typeface is recommended for viewing the table.
> ----------------------------------------------
> CONDITION CONDITION
> ALWAYS ALWAYS
> FALSE TRUE
> ----------------------------------------------
> :For(X,1,100 :For(X,1,100
> 2.4s :If X>100 1.4s :If X<100
> :X+1->X :X+1->X
> :End :End
>
> :For(X,1,100 :For(X,1,100
> 1.8s :X+(X>100->X 1.0s :X+(X<100->X
> :End :End
>
> :For(X,1,100 :For(X,1,100
> 1.8s :X+(X<0->X 1.0s :X+(X>0->X
> :End :End
> ----------------------------------------------
> The last two examples show that the test used is irrelevant,
> ie: same time whether you use >,<,>=,<=,<>, or =.
>
> Sincerely,
> The Unibomer
>
> Jared Ivey
> Unibomer@Juno.com
> http://www.geocities.com/SiliconValley/Vista/7342
>
> "It's a useless but absolutely vital precaution." -- Unknown
>
> _____________________________________________________________________
> You don't need to buy Internet access to use free Internet e-mail.
> Get completely free e-mail from Juno at http://www.juno.com
> Or call Juno at (800) 654-JUNO [654-5866]
Oh good! So I can use LESS mem and it should work slightly faster!
Jody Snider
jody1@alaska.net
References: