in reply to Re^4: Fastest way to lookup a point in a set
in thread Fastest way to lookup a point in a set

From the docs: The default subscript separator is "\034", the same as SUBSEP in awk

It's not "," , that's just the placeholder in Perl's syntax.

I don't know and can't think of any number format or localization which uses chr(28) .

Printable characters start from chr(32) onwards.

update

to avoid confusion

hex, oct, dez

perl -e "print 0x1c,034,28" 282828

Cheers Rolf
(addicted to the Perl Programming Language and ☆☆☆☆ :)
Je suis Charlie!

Replies are listed 'Best First'.
Re^6: Fastest way to lookup a point in a set
by swl (Prior) on Aug 07, 2017 at 23:53 UTC

    Thanks for clarifying.

    Here are some more examples for those reading later and who haven't previously had to work with non-printing characters in this way (e.g. me a few hours ago):

    # default $; does not print perl -e 'print join $;, 1..5' 12345 # but $; is still in the string perl -e '@x = split ($;, join ($;, 1..5)); print join ":", @x' 1:2:3:4:5

    That still does leave the issue of debugging using print statements, as [5,55] and [55,5] will both print as 555 on a terminal. The point is effectively moot, though, as the other posts have shown multidimensional indexing is slower and should probably not be used in this case.