Re: TIB: Re: TI-89 Basic question


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

Re: TIB: Re: TI-89 Basic question




In a message dated 03/23/2000 8:58:31 PM Eastern Standard Time, 
gbjohnson@yahoo.com writes:

<< I know what it is.
 type out this:
 solve(3=5*2+c,c)
 and the result is "c=-7".
 
 solve adds in the "c=" part to it, and then when you store that in b.
 so whenever you use b in the rest of hte program, it is a string that
 is in the form "c=#".
 
 so what you can do is rewrite the program so that it doesn't need the
 solve for c at all.
 
 if you solve y=mx+b for b, you get y-mx=b. then you can substitute
 that back in the program, and condense a few things and you will get
 this:
 
 ()
 Prgm
 Local  x,y,xx,yy,m
 Prompt  x,y,xx,yy
 (yy-y)/(xx-x)ğm
 Disp  "Slope is "&string(m),"y="&string(m)&"x+"&string(y-m*x)
 EndPrgm
 
 that should work like you want.  and it should be slightly faster and
 smaller. >>


thanks.