Skip to content

UnsameQ

Status: Stable

documented, exercised by the test suite and/or worked examples, with no known limitations recorded.

Description

lhs =!= rhs or UnsameQ[lhs, rhs]
    is the negation of SameQ: True iff lhs and rhs are not structurally
    identical.

Examples

No verified examples yet for this function.

Implementation notes

builtin_unsameq is the negation of structural identity over all argument pairs. With fewer than two arguments it returns True; otherwise it checks every pair (i,j) with expr_eq and returns False as soon as any two are structurally equal, else True. Like SameQ it uses no numeric coercion and always yields a definite boolean.

Attributes: Protected.

Implementation status

Stable — documented, exercised by the test suite and/or worked examples, with no known limitations recorded.

References

Notes & additional examples

Worked examples

In[1]:= a =!= b
Out[1]= True

In[2]:= a =!= a
Out[2]= False

Notes

UnsameQ (=!=) is the structural negation of SameQ; it always decides to True or False.