Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re^4: Repurposing reverse

by ikegami (Patriarch)
on Jan 31, 2011 at 09:01 UTC ( [id://885216]=note: print w/replies, xml ) Need Help??


in reply to Re^3: How to reverse a (Unicode) string
in thread How to reverse a (Unicode) string

As for the question you added,

Explain why you think this……should produce different output than this…

I agree that there should be a function that does that, but it's not reverse.

Explain why you think

my $water_samples = join '', map chr, 113, 101, 769; my $last_sample = substr($water_samples, -1, 1); print(ord($last_sample), "\n");

should produce different output than

my $water_samples = join '', map chr, 113, 101, 769; $water_samples = reverse($water_samples); my $last_sample = substr($water_samples, 0, 1); print(ord($last_sample), "\n");

Update: Corrected my numbers.

Replies are listed 'Best First'.
A reply falls below the community's threshold of quality. You may see it by logging in.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (4)
As of 2024-04-24 07:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found