fastern pattern test
- To: mathgroup at smc.vnet.net
- Subject: [mg123128] fastern pattern test
- From: borges2003xx <borges2003xx at gmail.com>
- Date: Thu, 24 Nov 2011 06:55:50 -0500 (EST)
- Delivered-to: l-mathgroup@mail-archive0.wolfram.com
please help a beginner. I need to clear every list in which there are two sublist with a property (in this case,equals and with length >= 2) ,not overlapping. Is there a faster way, perhaps using PatternTest (?). Thanx in Advance Clear[mm] mm[{___, b1__, ___, b1__, ___}] := {} /; Length[{b1}] >= 2 mm[l_] := l pool = Strings[{0, 1}, 6]; s1 = Rest[Union[Map[mm, pool]]] Best Regards