Recognize Twin Primes by Crashing
TI-BASIC, ~269

Input N
Lbl 1
2→P                                       :"  test N for divisibility by each prime
Lbl 2
If int(N/P)=N/P:Goto 3    :"composite"
If PP&gt;N:Goto 4
P+1→P
Goto 2
Lbl 3
Disp "                NOT PRIME.               "
Stop
Lbl 4
If int((N+2)/3)=(N+2)/3                    :" determine which nearby value to test
Then:N-2→R
Else:N+2→R
End
2→P
Lbl 5
If int(R/P)=R/P:Goto 6    :"composite"
If PP&gt;R:Goto 7
P+1→P
Goto 5
Lbl 6
Output("ISOLATED PRIME.")
Lbl 7          :" TI-BASIC how two ways of printing:
               :" Disp goes to the main screen,
               :" and Output goes to the graphical screen.
               :" This program uses both methods.
If R=N+2:Goto 5              :" go to print "lower twin prime"
Disp "UPPER TWIN PRIME"
Goto 7          :" only 16 chars can be printed per line, so we'll do the period separately (last line of program)
Lbl 5
Output("LOWER TWIN PRIME")
Lbl 7
Disp "."



   The NOT PRIME string has sixteen leading spaces, so nothing (except an ellipsis) will be printed, as noted in the comments.
 The ISOLATED PRIME string uses the Output() function, which requires two numbers (the coordinates of the printing location). This triggers an Argument Error.
 The LOWER TWIN PRIME string is indicated by the link to Lbl 5, which was already defined as the start of the twin prime test, causing an infinite loop.
 The UPPER TWIN PRIME string is followed by a link to the period, but Lbl 7 was already defined above, triggering an infinite loop.