Lingua::Pangram
Tony Bowden
tony at kasei.com
Wed Jan 23 09:47:05 CST 2002
On Wed, Jan 23, 2002 at 03:43:35PM +0000, Stray Toaster wrote:
> > > Your entries should behave in the same way as the above example: it
> > > should print any input lines that are pangrams.
> >
> > I'm not convinced yours does that ...
> What about....
>
> perl -e 'sub m{1if ord()>64&&ord()<123}foreach(split"",shift){$t{$_}++if
> m($_)}print %t==26?1:0' "abcdeghijklnmopqrstuvwxyz"
> or have I missed the point again?
Your entry should run against a load of entries and print out the ones
that are pangrams...
i.e. create a file "data" that looks something like:
the quick brown fox jumps over the lazy dog
the quick brown fox Jumps over the lazy dog
This one shouldn't match
abcdefghiJklmnopqrstuvwxyz
Then run...
perl <your-entry> < data
and ensure it prints out lines 1,2 and 4...
Tony
More information about the Belfast-pm
mailing list