Hi Chris, I suspect you're right. For the archives, on my attempt to solve this I came across the following useful modules:
Regexp::List - builds regular expressions out of a list of words Regexp::Parser - base class for parsing regexes String::REPartition - Generates a regex to partition a data set (Not very useful for my problem because regex is generic and simply designed to achieve a statistical objective) YAPE::Regex - Yet Another Parser/Extractor for Regular Expressions YAPE::Regex::Explain Mark. On Fri, 2004-08-27 at 09:21, Chris Devers wrote: > On Fri, 27 Aug 2004, Mark Maunder wrote: > > > I've google'd and CPAN'd and no luck. Is there a tool out there that > > will generate a regular expression based on a series of string inputs > > that are similar but have parts that differ[?] > > I suspect that this is a Hard problem, as in NP-Hard/NP-Incomplete, as: > > <http://en.wikipedia.org/wiki/NP-hard> > <http://en.wikipedia.org/wiki/NP-complete> > > <http://mathworld.wolfram.com/NP-HardProblem.html> > <http://mathworld.wolfram.com/NP-Problem.html> > <http://mathworld.wolfram.com/NP-CompleteProblem.html> > > Rather than trying to find a tool for this, you'll be much better off > trying to come up with an understanding of what within the patterns that > you match are the qualities that you want to match against, and then > finding a way to express this terms that the computer, by way of regular > expressions, can understand your intent. > > My hunch is that flinging a bunch of text at some kind of regex maker > and telling it to figure out on its own how to match or not match > different examples is going to be a variant of the halting problem. > > <http://en.wikipedia.org/wiki/Halting_problem> > <http://mathworld.wolfram.com/HaltingProblem.html> > > And I'd be stunned if you could solve that by the end of the day :-) > > > -- > Chris Devers -- Mark D. Maunder <[EMAIL PROTECTED]> http://www.workzoo.com/ "The Best jobs from the Best Job Sites." -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>