Omnimaga
Calculator Community => TI Calculators => TI-BASIC => Topic started by: blue_bear_94 on March 18, 2013, 09:20:19 pm
-
So the challenge is to compose a program that works both on 83+ Basic and 68k Basic, in similar fashions. The example below clears the screen and prints "Hello World!" (This is only the body):
If sin(1)=.841470984808
ClrHome
CLRIO
Disp "Hello World!"
Edit: sin(1) is equal to .841470984808 on the 83/84+, due to it comparing only ten significant figures, but these two values are different on a CAS calc such as the TI-89. So if you have an 83/84+, the program runs ClrHome; otherwise, it runs ClrIO (the expression CLRIO is treated as the product of five variables on the 83+ but the ClrIO command on the 68k). The final line is identical for both models.
-
(the expression CLRIO is treated as the product of five variables on the 83+ but the ClrIO command on the 68k).
Well, that's kinda cheating.
-
The problem is that both calcs use different token sets and prog formats so you'd still have to convert them with a comp.
-
Yeah true. THe best thing would be if there was some token converter somewhere that replaced ClrIO with ClrHome or vice-versa.
Also are commands on 68K calcs case-sensitive?
-
Yeah true. THe best thing would be if there was some token converter somewhere that replaced ClrIO with ClrHome or vice-versa.
Also are commands on 68K calcs case-sensitive?
Well, I was ignoring tokens, and commands are not case-sensitive on the 68k.