MathGroup Archive 2004

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

Search the Archive

Re: use of orderless

  • To: mathgroup at smc.vnet.net
  • Subject: [mg52630] Re: use of orderless
  • From: Peter Pein <petsie at arcor.de>
  • Date: Sun, 5 Dec 2004 02:08:07 -0500 (EST)
  • References: <cohj5k$1nb$1@smc.vnet.net><cok9c2$jtk$1@smc.vnet.net> <cos0rp$dic$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

borges2003xx at yahoo.it wrote:
> sorry
> the right is "SetAttributes[mmQ, Orderless]"
> mmQ is a function feeded by a, b c. They have to be sublist of length
> 
>>=3 and a (xor) b ==c.
> 
> the  problem that i need that a,b,c must be interchangable.
> thanx
> 
mmQ[a_,b_,c_]:=If[Length/@{a,b,c}=={3,3,3},Thread[BitXor[a,b,c]]=={0,0,0},False]

should do this job.

-- 
Peter Pein
10245 Berlin


  • Prev by Date: Installing 5.1 without 5.0?
  • Next by Date: Compile with ReplaceList
  • Previous by thread: Re: use of orderless
  • Next by thread: Re: New User - Programming