Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: y/·/./ gives two points instead of one

by ikegami (Patriarch)
on Nov 16, 2015 at 21:38 UTC ( [id://1147845]=note: print w/replies, xml ) Need Help??


in reply to y/·/./ gives two points instead of one

You think you have

$_ = '·|·'; print y/·/./r, "\n"; print s/·/./gr, "\n";

but you actually have

$_ = '·|·'; print y/·/./r, "\n"; print s/·/./gr, "\n";

This is because you treated the file as UTF-8 when you viewed it, but you didn't tell Perl to do the same by adding use utf8;.

Replies are listed 'Best First'.
Re^2: y/·/./ gives two points instead of one
by rsFalse (Chaplain) on Nov 16, 2015 at 21:53 UTC
    Thanks for explanation!

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (4)
As of 2024-04-23 19:52 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found