Re: Programming challenge: wildcard exclusion in cartesian products
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.python archive

Re: Programming challenge: wildcard exclusion in cartesian products

From: Aaron Denney <wnoise@ofb.net>
Date: Thu Mar 23 2006 - 18:28:56 CET

On 2006-03-23, wkehowski@cox.net <wkehowski@cox.net> wrote:
> The solution that would have the most utility would be one where the
> elements are generated one-by-one, loop-like, so that they can be used
> in the body of a loop, and to avoid the fact that even with exclusion
> the cardinality of the target set EX^n could be in the millions even
> with a full list of wc's, that is, a list containing at least one wc of
> every length in 2..(n-1). I don't know enough Lisp, Haskell or
> Qi/Prolog to know if the solutions so far can be modified to do this.
> The Python program is too slow for large sets.

In Haskell you can get this essentially for free, due to its laziness.

-- 
Aaron Denney
-><-
Received on Sun Apr 30 20:58:38 2006