Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

RE: RE: RE: Re: Search Algorithm

by chromatic (Archbishop)
on Aug 10, 2000 at 20:53 UTC ( #27330=note: print w/ replies, xml ) Need Help??


in reply to RE: RE: Re: Search Algorithm
in thread Search Algorithm

Keys in a hash are case sensitive, but nothing says you have to store them in a particular case. Pseudo-workable snippet follows:

foreach (@words) { $word_idx{lc($_)} = $position; }
The important magic is in lc. You'll have to use lc when you pull values out of the hash, too, or use a tied hash that does this for you.


Comment on RE: RE: RE: Re: Search Algorithm
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://27330]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (6)
As of 2014-10-25 22:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (149 votes), past polls