[PD] simple message/list parsing

Mathieu Bouchard matju at artengine.ca
Fri Oct 5 20:31:00 CEST 2007


On Tue, 18 Sep 2007, Ken Restivo wrote:
> On Tue, Sep 18, 2007 at 10:22:25PM +0200, Thomas Grill wrote:
>>> Install the ruby external, and make a simple external that does this?
>>> 	set1 & set2
>>> and does it all in linear time too, instead of (presumably) quadratic.
>> it's the exact same syntax for Python (starting with version 2.4)
> Thanks. I haven't done much with Python since the 2.3 days.
> Um, actually, it looks like it's more like:
> 	list( set(set1) & set(set2) )

Ok, it's not really the same. Ruby has no Set class, there's no & for 
Hashes, and the & for Arrays preserves order of elements of the left-hand 
side.

  _ _ __ ___ _____ ________ _____________ _____________________ ...
| Mathieu Bouchard - tél:+1.514.383.3801, Montréal QC Canada


More information about the Pd-list mailing list