You can do a lot of programming without using a regex. I know. I did it. But if you use sites like this, you will see posts that mention regexes and then, when you are trying to write something, you will realise that a regex is the best tool. That's the best tutorial you can find - a need to solve a problem of your own. Unless you have to pass an exam, don't try learning something you don't use, as you will quickly forget what you learned. Once you get to wanting to learn something, try writing the regex yourself. If you get stuck, post here with what you are trying to do and what you have written. When I've done this, I've found the Monasteriat extremely helpful.

As others have said, some regexes are very simple. But as I think you realised before the other posts, regexes are a very powerful tool (I don't know them at all well, but I know that much). And in addition to the tools others have mentioned, I have recently taken to using Damian Conway's Regexp::Debugger, which I have found most helpful.

Regards,

John Davies


In reply to Re: Regex, the jungle survival skill by davies
in thread Regex, the jungle survival skill by mmkstarr

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.