Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask

Re: What are these hex character classes?

by Kenosis (Priest)
on Dec 08, 2013 at 00:37 UTC ( #1066167=note: print w/replies, xml ) Need Help??

in reply to [Solved] What are these hex character classes?

From Prelre:

\x{}, \x00 character whose ordinal is the given hexadecimal number

The \x denotes the beginning of a hexadecimal value.

Also see: Unicode character table.

Replies are listed 'Best First'.
Re^2: What are these hex character classes?
by three18ti (Scribe) on Dec 08, 2013 at 01:35 UTC
    This is great. Thank you!

    So like most things in computing, the zeros are omitted, so \x{A} is actually \x{000A}.

      You're most welcome, three18ti!

      Perl expectedly parses both as "\n" (the leading zeros aren't significant):

      perl -MO=Deparse,-p -e 'print "\x{A}"'


      print("\n"); -e syntax OK


      use warnings; use strict; print ord "\x{A}" if "\x{000A}" eq "\n";



      As you see, \x{A}, \x{000A} and \n all represent the same character.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1066167]
[MidLifeXis]: Nothing like encouraging the success of a rollout by neutering your current support structure without a reasonable staffed and trained replacement structure.
[MidLifeXis]: Speaking of which, anyone know of Perl positions in the MKE area (or slightly west)?
[Corion]: MidLifeXis: Oh, enjoying the show from the sidelines I see...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (10)
As of 2017-03-23 12:28 GMT
Find Nodes?
    Voting Booth?
    Should Pluto Get Its Planethood Back?

    Results (286 votes). Check out past polls.