Re: How to check if something in one array is in another

2008-06-15 Thread Tim Chase
> The two arrays are just normal dictionaries that look something like > this: > > friends = [id=1,id=2,id=3] > friends2 = [id=3] This is the first suspicious item because if it is a dictionary, the key "id" appears more than once -- something that can't happen with a dict. Sets are the usual

How to check if something in one array is in another

2008-06-15 Thread Darthmahon
Hi Guys, I'm trying to do a hash lookup with two arrays. Basically, I have a friends list and another list that has user id's. I want to check if any of the user id's I have are also in the friends list. The two arrays are just normal dictionaries that look something like this: friends = [id=1,