Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked

Re: Why are my hyphens in number strings stored as dots?

by oko1 (Deacon)
on Feb 14, 2012 at 03:07 UTC ( #953592=note: print w/replies, xml ) Need Help??

in reply to Why are my hyphens in number strings stored as dots?

I'll agree with GrandFather, and add one: how about you show us the data, too - maybe by running it through 'hexdump -C' or some equivalent?

#!/usr/bin/perl -w use strict; my $s1 = "1\xe2\x80\x932\xe2\x80\x933"; my $s2 = "1-2-3"; print "$s1: not $s2, but a brilliant imitation!\n" unless $s1 eq $s2;


1𣇽: not 1-2-3, but a brilliant imitation!

Depending on your character set, those n-dashes could well end up looking like dots, etc.

I hate storms, but calms undermine my spirits.
 -- Bernard Moitessier, "The Long Way"

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (13)
As of 2016-10-28 18:01 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (386 votes). Check out past polls.