This is an archived, read-only copy of the United-TI subforum , including posts and topic from May 2003 to April 2012. If you would like to discuss any of the topics in this forum, you can visit Cemetech's TI-BASIC subforum. Some of these topics may also be directly-linked to active Cemetech topics. If you are a Cemetech member with a linked United-TI account, you can link United-TI topics here with your current Cemetech topics.

This forum is locked: you cannot post, reply to, or edit topics. TI-Basic => TI-BASIC
Author Message
Jedd
1980 Pong World Champion


Elite


Joined: 18 Nov 2003
Posts: 823

Posted: 21 Nov 2003 06:48:07 pm    Post subject:

I've read a lot of places that instead of

If A=2 and B=7

you should make it run faster by writing

If (A=2)(B=7)

But does this really make the program run faster? It seems like it would take the calc longer to multiply the two statements than to just see if they were both true.
Back to top
Arcane Wizard
`semi-hippie`


Super Elite (Last Title)


Joined: 02 Jun 2003
Posts: 8993

Posted: 22 Nov 2003 07:51:41 am    Post subject:

Yes, it is indeed faster.
Back to top
WhiteDwarf


Newbie


Joined: 10 Nov 2003
Posts: 19

Posted: 22 Nov 2003 12:18:58 pm    Post subject:

There's another thread in this forum all about that....i think it's like one thread below this called If Then statements
Back to top
NETWizz
Byte by bit


Bandwidth Hog


Joined: 20 May 2003
Posts: 2369

Posted: 22 Nov 2003 01:23:53 pm    Post subject:

Instead of

If X(not equal)0

Try

If X
Back to top
DarkerLine
ceci n'est pas une |


Super Elite (Last Title)


Joined: 04 Nov 2003
Posts: 8328

Posted: 22 Nov 2003 01:45:09 pm    Post subject:

here are the ones I use (I am going to repeat some):


Code:
If X (not equal) Y
is slower than
If X-Y

If X or Y
is slower than
If X+Y (won't work if one or both can be negative)

If X and Y
is slower than
If XY

If X=0
is slower than
If not(X

If X=1
is slower than
If X (i am assuming X = 0 or X = 1 in this case)


Last edited by Guest on 26 Nov 2003 02:40:49 pm; edited 1 time in total
Back to top
Arcane Wizard
`semi-hippie`


Super Elite (Last Title)


Joined: 02 Jun 2003
Posts: 8993

Posted: 23 Nov 2003 01:38:58 pm    Post subject:

I could merge this topic to the other topic, but it appears this is no longer possible. Sad
Back to top
Display posts from previous:   
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
    »
» View previous topic :: View next topic  
Page 1 of 1 » All times are UTC - 5 Hours

 

Advertisement