in reply to challenging the dictionary
Good luck, this is exactly the NP-complete Minimum Set Cover problem (which makes me hope it's not homework). The universe is the set of letters, the family of subsets is the dictionary of words. You want to minimize the number of words needed to use all the letters in the alphabet, in other words, the number of subsets needed such that each element in the universe is contained in at least one chosen subset.
You won't be able to do significantly better than brute force, unless an approximation algorithm would also be appropriate for your needs. But with a huge dictionary, the running time is going to be intractable.
blokhead
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: challanging the dictionary
by Limbic~Region (Chancellor) on Apr 23, 2006 at 23:11 UTC | |
Re^2: challanging the dictionary
by Limbic~Region (Chancellor) on Oct 25, 2006 at 14:28 UTC |
In Section
Seekers of Perl Wisdom