Login [Register]
Don't have an account? Register now to chat, post, use our tools, and much more.
I have dont know what is going wrong with my code, but when i print it via my TI 84 Plus, the solution shows for 0,00000001 second and then disappears... How can i make it last on my screen?

Code:
startTmr
ClrHome
Disp "AX²+BX+C=0
Prompt A,B,C
B²-4AC→D
PlotsOff :FnOff :ClrDraw:AxesOff:ZStandard
Line(3.8,10,10,10:Line(3.8,10,3.8,3.7:Line(3.8,3.7,10,3.7:Line(10,3.7,10,10
Text(7,67,"(C) 2004
Text(13,68,"B.L. V5B
Text(1,68,"VER: 3.1
Text(1,15,"FORMULA:
If B≥0 and C≥0
Text(9,1,A,"X²+",B,"X+",C,"=0
If B<0 and C≥0
Text(9,1,A,"X²-",­B,"X+",C,"=0
If B≥0 and C<0
Text(9,1,A,"X²+",B,"X-",­C,"=0
If B<0 and C<0
Text(9,1,A,"X²-",­B,"X-",­C,"=0
Text(18,15,"D=B²-4AC =
Text(26,1,B,"²-4*",A,"*",C,"=",D)
If D≠0
Text(34,15,"SOLUTIONS:
If D=0

If D<0
Then
Text(47,1,"NO SOLUTIONS
Goto 1
End
(­B-√(D))/(2A)→E
(­B+√(D))/(2A)→F
Text(47,1,"X=
Text(41,6,­B,"-√(",D,")
Line(­7.5,­5.4,­3,­5.4
Text(49,15,"2*",A
Text(57,1,"X=",E
If D=0
Then
Goto 1
Else
Text(47,38,"OR
Text(47,50,"X=
Text(41,55,­B,"+√(",D,")

Text(49,65,"2*",A
Text(57,50,"X=",F
End
Lbl 1
P
ClrDraw:ZPrevious:AxesOn :ClrHome:FnOn
DelVar ADelVar BDelVar CDelVar DDelVar EDelVar FDelVar Y
Stop

Pls help !
svafa wrote:
I have dont know what is going wrong with my code, but when i print it via my TI 84 Plus, the solution shows for 0,00000001 second and then disappears... How can i make it last on my screen?
[...]
Pls help !

You ClrDraw at the end, which erases everything on the screen. Simply remove the ClrDraw on the 2nd to last line.
You may want to consider optimizing your code. I see a lot of redundant statements, and using the graphscreen seems like a bit of a drag. I suggest going through each line and asking "what does this do?"
That will help you identify what is not needed, and maybe familiarize you a bit more with the different commands.
Well-stated, Mr. Womp Womp. Welcome to Cemetech, svafa, and good luck with your program. Where you have "P" before your "ClrDraw", did you mean to add "Pause "? Is this something you created yourself, or copied/modified from elsewhere? I have some resources I might suggest to help you learn TI-BASIC more rigorously, but other people here might clamor about self-promotion.
KermMartian wrote:
I have some resources I might suggest to help you learn TI-BASIC more rigorously, but other people here might clamor about self-promotion. ;)
Fixed.

But seriously, KermMartian teaches compsci at NYU, so his book is legit.

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.

»
» All times are GMT - 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