TI Programming, CRYPTO!


[Prev][Next][Index][Thread]

TI Programming, CRYPTO!



Thanks a lot for your help in my previous thread.  I only know a little bit
of ASM, and am fairly well aquatinted with Quick BASIC, and am trying to get
used to BASIC.  I was wondering if I could get some help with a program I'm
trying to write, it is an extra-credit program. (And I can use to get even
more extra-credit in the future:)  Here is what I need

My Honors Geometry teacher has this little game we play every day, called
CRYTO.  Basically, you are given 6 numbers, and you use the first 5 to solve
for the 6th.  For example, one CRYPTO was
4 2 9 3 8=17
I quickly came up with
4/2 radical 9 *3 + 8=17

This doesn't look right, but I don't know of any ASCII radical symbol.  But
basically, in order to take the square root of something, you would have to
have a 2, (The 4/2=2) then use that to take the square root of 9, so you
have a 3.  Then multiply 3 *3 to get 9, and add an 8 to get 17.   Basically,
you can add, subtract, devoid (both ways, using the division sign, or the
long division sign if the numbers needed to be flipped), multiply, square
(or use any number that follows a number, if it were a 9 and a 2, you'd have
2 squared... 9 and 3, 9 cubed exc....) or take the root (also square root,
cube root exc...)

Well, I asked a while back if any of his other students have tried a
program, and he said all have failed.  So, I got to work.  We'll, I'm about
to quit my self.  The way I have it planned it, you would set up some inputs
to enter the six numbers, the set up a routine like Randgen that take four
variables and uses the randint function.  Set up the randint function to
randint(1-6) for each variable.  Remember, we have addition, subtraction,
multiplication, both types of division, square roots and powers.

But, how would I go about setting up a routine to take that randomint
variable, such as L1, and use it to apply a calculator function.  No matter
what I try, I get a syntax error.  Any ideas?


Follow-Ups: