pp $_ for map{ { m[([A-Z])([0-9.]+)]g } } split"\n", <<EOD; N260G02X142.05Y649.62I77.33J58.34H2M25 N265M20 N270G45 N275G01X304.78Y608.8C45.91M25 N280M20 N285G46C0 N290G03X324.39Y638.4I-69.58J67.4H2M25 N295M20 N300G45 N305G01X180.04Y592.89C326.5M25 N310X279.77Y586.78C26.5 N315X195.39Y584.57C336.5 N320X228.31Y579.58C355.92 EOD ;; { G => 02, H => 2, I => 77.33, J => 58.34, M => 25, N => 260, X => 142 +.05, Y => 649.62 } { M => 20, N => 265 } { G => 45, N => 270 } { C => 45.91, G => 01, M => 25, N => 275, X => 304.78, Y => 608.8 } { M => 20, N => 280 } { C => 0, G => 46, N => 285 } { G => 03, H => 2, J => 67.4, M => 25, N => 290, X => 324.39, Y => 638 +.4 } { M => 20, N => 295 } { G => 45, N => 300 } { C => 326.5, G => 01, M => 25, N => 305, X => 180.04, Y => 592.89 } { C => 26.5, N => 310, X => 279.77, Y => 586.78 } { C => 336.5, N => 315, X => 195.39, Y => 584.57 } { C => 355.92, N => 320, X => 228.31, Y => 579.58 }

With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
I'm with torvalds on this Agile (and TDD) debunked I told'em LLVM was the way to go. But did they listen!

In reply to Re: Efficient split for alpha numeric pairs in a row by BrowserUk
in thread Efficient split for alpha numeric pairs in a row by merrymonk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.