MathGroup Archive 2006

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

Search the Archive

Re: finding the position of a pattern in list

  • To: mathgroup at smc.vnet.net
  • Subject: [mg64621] Re: finding the position of a pattern in list
  • From: bghiggins at ucdavis.edu
  • Date: Fri, 24 Feb 2006 00:18:17 -0500 (EST)
  • References: <dtjjcv$de7$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

Gang Ma,

Try this :
 Data=0,0,1,1,1,0,0,1,1,1,0}


Position[Partition[data,2,1],{0,1}]

{{2},{7}}

Cheers,

Brian


  • Prev by Date: Multivariable Limits
  • Next by Date: Re: finding the position of a pattern in list
  • Previous by thread: Re: finding the position of a pattern in list
  • Next by thread: Re: finding the position of a pattern in list