Show More
@@ -2227,6 +2227,14 b' class orderedlazyset(lazyset):' | |||
|
2227 | 2227 | def filter(self, l): |
|
2228 | 2228 | return orderedlazyset(self, l, ascending=self._ascending) |
|
2229 | 2229 | |
|
2230 | def __and__(self, x): | |
|
2231 | return orderedlazyset(self, lambda r: r in x, | |
|
2232 | ascending=self._ascending) | |
|
2233 | ||
|
2234 | def __sub__(self, x): | |
|
2235 | return orderedlazyset(self, lambda r: r not in x, | |
|
2236 | ascending=self._ascending) | |
|
2237 | ||
|
2230 | 2238 | class generatorset(object): |
|
2231 | 2239 | """Wrapper structure for generators that provides lazy membership and can |
|
2232 | 2240 | be iterated more than once. |
General Comments 0
You need to be logged in to leave comments.
Login now