Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
My question for all the wise monks is how can you compare $info to $infounknown when one is the actual string you're looking for while the other is using a glob of asterics as placeholders? My other question is, how do you then replace all instances of characters you type in (or word) for $infounknown.
An example would be something like: $info= "I am a brown icecube" and $infounknown would be "* ** * ***** *******". When the person searches for the letter A, it would then show '* a* a ***** *******'.
Questions: how can you use one as placeholders but still verifiy the values? How can you replace the values in $infounknown if they exist?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: string matching/replacing
by broquaint (Abbot) on Sep 06, 2003 at 22:37 UTC | |
|
Re: string matching/replacing
by antirice (Priest) on Sep 06, 2003 at 20:30 UTC | |
by knexus (Hermit) on Sep 06, 2003 at 20:44 UTC | |
|
Re: string matching/replacing
by sgifford (Prior) on Sep 07, 2003 at 04:10 UTC | |
|
Re: string matching/replacing
by graff (Chancellor) on Sep 07, 2003 at 03:56 UTC |