Last active
August 29, 2015 14:08
-
-
Save JeffreyO/5df5b38ead78ffc0ce24 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This is a program for testing if a line is Parallel, Perpendicular, | |
or Neither for the TI line of graphing calculators. | |
It is written in TI-Basic. | |
PROGRAM: TESTSLOP | |
:Input "SLOPE 1: ",A | |
:Input "SLOPE 2: ",B | |
:(AB)->C | |
: | |
:If C=-1 | |
:Then | |
:Disp "PERP" | |
:Else | |
:If C=A^2 and C=B^2 | |
:Then | |
:Disp "PARALLEL" | |
:Else | |
:Disp "NEITHER" | |
:End |
Never mind: I had a brain fart. -5*5=-25
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Issue: If AB=-1 and A=-5, B=5 the program will return a false string of PERP instead of the correct string of NEITHER. Do any of you have an equation that will prevent this?