Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Word Comparison

by nefigah (Monk)
on Mar 26, 2008 at 22:45 UTC ( #676574=note: print w/replies, xml ) Need Help??


in reply to Word Comparison

Sounds like a fun task, and regular expressions will be your friend here... but from the example you listed, I'm not sure if the rules are totally clear to me? Could you come up with a list of criteria for "what makes a word close enough to another word"? Then we can give some more concrete ideas :)


I'm a peripheral visionary... I can see into the future, but just way off to the side.

Replies are listed 'Best First'.
Re^2: Word Comparison
by rooneyl (Sexton) on Mar 26, 2008 at 22:58 UTC
    I'll try an explain how the game works.
    You are presented with a word, for example 'perlmonksisgreat'.
    You have to try and make words from this using only the letters that are in the word, you can only use each letter as many times as it appears. In the above example you could use 1 x 'p' and 2 x 'e' and so on.
    Some examples of valid words are 'perl', 'slop', 'term'.
    An example of a non-valid word would be 'pepper' (only 1 'p').

      Ah, in that case, use pc88's first example below, it does exactly what you want :)


      I'm a peripheral visionary... I can see into the future, but just way off to the side.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://676574]
help
Chatterbox?
[Eily]: Hello :)
[karlgoethebier]: Good morning
[Discipulus]: hello karlgoethebier, what about your nigth guitar performance?
[marto]: people have the option to easily ignore/hide sigs. I don't think it's any real cause for concern. If something were overly offensive I'd hope it'd get reported and discussed

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (12)
As of 2017-06-23 08:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How many monitors do you use while coding?















    Results (538 votes). Check out past polls.