Should this topic be split?
I do believe that it should be. Good call, Dan.

so how bout those inc and dec commands?
KermMartian wrote:
Of course. I think that they were kinda a waste of space though, and that TI should have used those tokens for more useful commands.


Now the really wierd thing with this is that I just noticed that Casio BASIC (I also own a Casio Prizm) had these same two essentially useless commands. Now, why would that be?
iconmaster wrote:
KermMartian wrote:
Of course. I think that they were kinda a waste of space though, and that TI should have used those tokens for more useful commands.


Now the really wierd thing with this is that I just noticed that Casio BASIC (I also own a Casio Prizm) had these same two essentially useless commands. Now, why would that be?
I noticed that too, and was equally baffled. I decided that it must be part of an attempt to make Casio BASIC have at least all the features from TI-BASIC and more, thus appealing to people who original started as TI-BASIC coders before moving to Casio calculators. Actually, looking back at the first post in this topic, where TIFreak explains IS>() and DS<(), I'm starting to re-think my dismissal of the two tokens as useless.
IS> and DS< seem to be carry-overs from the TI-81, which had no real looping commands. These commands were pretty much how you would have to do loops on that calc. I guess for some reason TI decided not to remove them.
Well, they aren't good for looping, more a shortened version of If Then Else End, if anything.
They can be used with gotos, where one goto jumps backward in the code, to effect a loop, as in calc84maniac's example.
It's true, though that is far from efficient or speedy. :p I just ignore that Lbl's and Goto's exist so I never think about them being used at all.
Yeah, they really make don't make much sense on modern calculators. I was just pointing out that they were all one had back on the old TI-81, before the TI-85 introduced “real” looping commands.
Travis wrote:
Yeah, they really make don't make much sense on modern calculators. I was just pointing out that they were all one had back on the old TI-81, before the TI-85 introduced “real” looping commands.
I didn't know that; learned something today! Thanks for sharing that, Travis.
Hmm, maybe I'll try to relive the classical era of BASIC by only using labels, gotos, and IS/DS when making something Smile actually, that would pretty cool and fun.
The issue with that is using If's ends up being the same size byte wise due to IS and DS being two byte tokens iirc.
TheStorm wrote:
The issue with that is using If's ends up being the same size byte wise due to IS and DS being two byte tokens iirc.
Guess again; they're one-byte tokens. Smile


Code:
218 => 'IS&gt;(',
219 => 'DS&lt;(',
For the record, this is what I remember about IS and DS:
1. They were included on the 83 (no plus) for 82 compatibility. The 82 had no For() loop, so it had to be achieved with an IS/DS. I'm not 100% sure, but I think it also did not have While or Repeat. (Whoops, Travis beat me to this one)
2. The 82 had no 2 Byte tokens. Again, because of compatibility the tokens were kept in their previous locations.
3. The only time I've ever seen one used that's not just an example is in Darkerline's Donut Quest II.
ztrumpet wrote:
For the record, this is what I remember about IS and DS:
1. They were included on the 83 (no plus) for 82 compatibility. The 82 had no For() loop, so it had to be achieved with an IS/DS. I'm not 100% sure, but I think it also did not have While or Repeat. (Whoops, Travis beat me to this one)


Actually, the 82 had For(, While, and Repeat (at least my ROM 18.0 one does). They were added with the 85, which came out just before the 82. As you said, I think they left them in for compatibility and for users migrating from the TI-81 and never removed them from the Z80 calcs because they saw no reason to.
The TI-82 definitely has almost all the BASIC commands that the TI-83 and thence TI-83+ do; as Travis says, it's the TI-81 that had the stunted BASIC.
I Might actually have to start using these. The ablility it use it with labels could be useful.
Aes_Sedia5 wrote:
I Might actually have to start using these. The ablility it use it with labels could be useful.
Sounds cool; I hope you do! If you do, you need to share some of your code with us. I'd imagine a lot of us have never used IS/DS or seen them used in actual applications.
Ok. Right now I am rewriting all my programs that work better with repeat and while loops. Then I will go back and rewrite to use IS and DS. the only real good uses I see are for label loops.

For Example.

Code:

//Say there is a code to do synthetic division here. I have it somewhere just cant find it and dont want to rewrite it.
Z= the last variable which is the remainder.
IS<Z,1
goto AB
//AB = the start of the synthetic division code. but right after inputs So it just keeps going through to find the simplest possible expression.
Disp "Quadratic Formula?"
Disp "1=Yes", "0=No"
getkey->K
DS>(K,0
Goto ST
//ST = Start OF Program
//Then Quadratic equation written to use the variable from synthetic divison.
goto ST

It has been along weekend so there might be some errors there will have to test it later. But it might save a few bytes in programs. But basically it is still just a shortened If, Then, End loop. but 2 bytes less at the minimum
  
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
Page 2 of 3
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement