MathGroup Archive 1999

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: equaltity of lists

  • To: mathgroup at
  • Subject: [mg19067] Re: equaltity of lists
  • From: adam.smith at
  • Date: Thu, 5 Aug 1999 01:34:54 -0400
  • Organization: - Share what you know. Learn what you don't.
  • References: <7o5ih1$>
  • Sender: owner-wri-mathgroup at


Try using the triple equal === (SameQ).  There are subtle differences
between the == (Equal) and the === and I can not explain exactly what
they are.  But in this case == fails because it does not "know" what
the values of a and b are. So it just returns the original input which
is Mathematica's way of telling you it can not do this.  However ===
seems to do some things with pattern matching and returns the value

Adam Smith

In article <7o5ih1$rml at>,
  "Drago Ganic" <drago.ganic at> wrote:
> Hi !!
> Why don't I get an answer (False) when I ask Mathematica
>     {a,b}=={b,a}
> like the one I get with
>     {1,2}=={2,1}
>     False
> Greetings from Croatia,
> Drago Ganic

Sent via
Share what you know. Learn what you don't.

  • Prev by Date: Mathematica References for Efficient Programming?
  • Next by Date: Can someone explain why Mathematica is doing this?
  • Previous by thread: Re: equaltity of lists
  • Next by thread: Re: equaltity of lists