Skip to main content
Commonmark migration
Source Link

#TI-Basic, 70 69 bytes

TI-Basic, 70 69 bytes

Prompt A
For(B,1,A
For(C,1,B
For(D,1,C
(B+C+D)/2
If A2=Ansprod(Ans-{B,C,D
Then
Disp B,C,D
Return
End
End
End
End
/

Displays the three side lengths if there is a triangle, throws a syntax error if there isn't (thanks to the / at the end).

-1 byte thanks to Sean's comment on a different answer

#TI-Basic, 70 69 bytes

Prompt A
For(B,1,A
For(C,1,B
For(D,1,C
(B+C+D)/2
If A2=Ansprod(Ans-{B,C,D
Then
Disp B,C,D
Return
End
End
End
End
/

Displays the three side lengths if there is a triangle, throws a syntax error if there isn't (thanks to the / at the end).

-1 byte thanks to Sean's comment on a different answer

TI-Basic, 70 69 bytes

Prompt A
For(B,1,A
For(C,1,B
For(D,1,C
(B+C+D)/2
If A2=Ansprod(Ans-{B,C,D
Then
Disp B,C,D
Return
End
End
End
End
/

Displays the three side lengths if there is a triangle, throws a syntax error if there isn't (thanks to the / at the end).

-1 byte thanks to Sean's comment on a different answer

A^2=X instead of A=abs(sqrt(X
Source Link
pizzapants184
  • 3.6k
  • 16
  • 18

#TI-Basic, 7070 69 bytes

Prompt A
For(B,1,A
For(C,1,B
For(D,1,C
(B+C+D)/2
If A=abs(sqrt(AnsprodA2=Ansprod(Ans-{B,C,D
Then
Disp B,C,D
Return
End
End
End
End
/
 

Displays the three side lengths if there is a triangle, throws a syntax error if there isn't (thanks to the / at the end).

-1 byte thanks to Sean's comment on a different answer

#TI-Basic, 70 bytes

Prompt A
For(B,1,A
For(C,1,B
For(D,1,C
(B+C+D)/2
If A=abs(sqrt(Ansprod(Ans-{B,C,D
Then
Disp B,C,D
Return
End
End
End
End
/
 

Displays the three side lengths if there is a triangle, throws a syntax error if there isn't (thanks to the / at the end).

#TI-Basic, 70 69 bytes

Prompt A
For(B,1,A
For(C,1,B
For(D,1,C
(B+C+D)/2
If A2=Ansprod(Ans-{B,C,D
Then
Disp B,C,D
Return
End
End
End
End
/

Displays the three side lengths if there is a triangle, throws a syntax error if there isn't (thanks to the / at the end).

-1 byte thanks to Sean's comment on a different answer

Source Link
pizzapants184
  • 3.6k
  • 16
  • 18

#TI-Basic, 70 bytes

Prompt A
For(B,1,A
For(C,1,B
For(D,1,C
(B+C+D)/2
If A=abs(sqrt(Ansprod(Ans-{B,C,D
Then
Disp B,C,D
Return
End
End
End
End
/

Displays the three side lengths if there is a triangle, throws a syntax error if there isn't (thanks to the / at the end).