Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re^3: using hashes

by arrestee (Novice)
on Sep 26, 2013 at 15:58 UTC ( #1055858=note: print w/ replies, xml ) Need Help??


in reply to Re^2: using hashes
in thread iterating hash keys?

For an effective solution to your problem, see BrowserUK's comment below. As to why the code you've shown doesn't work, it's probably because you're storing each line of your file/array in $line, but doing your substitution against $_. Try this: $line =~ s/$find/$replace/g.


Comment on Re^3: using hashes
Select or Download Code
Re^4: using hashes
by R56 (Acolyte) on Sep 26, 2013 at 16:46 UTC
    Thanks arrestee, that suggestion did some of the trick, but still having the 'exact match' problem that I replied to Kenneth on top...

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (6)
As of 2014-08-23 04:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (172 votes), past polls