TrueQ

TrueQ[expr]
yields True if expr is True, and yields False otherwise.

DetailsDetails

  • You can use TrueQ to "assume" that a test fails when its outcome is not clear.
  • TrueQ[expr] is equivalent to If[expr,True,False,False].

ExamplesExamplesopen allclose all

Basic Examples  (1)Basic Examples  (1)

TrueQ will return True only if the input is explicitly True:

In[1]:=
Click for copyable input
Out[1]=
In[2]:=
Click for copyable input
Out[2]=
In[3]:=
Click for copyable input
Out[3]=
Introduced in 1988
(1.0)