Is there a good online interactive regular expression tutorial?

Now I know that SQL and regular expressions are just fine, but several times on this site I came across someone working on SQLzoo.net exercises. As far as I can tell, this was a wonderful online resource where someone can learn SQL quite easily, for example, by writing a lot of toy queries against several toy databases. I most likely redirect people who want to learn SQL on this site.

These SQLzoo people also run some other tutorials, including some in several programming languages. However, the regex section is pretty small (e.g. see the Java page), and I don’t think you can really learn regular expressions from it. I think a good online tutorial can help with the onslaught of the main questions of regex that we have here. (Maybe after the answer we could suggest that they take a look at the textbook.)

So, is there a good interactive interactive regular expression tutorial according to this SQL tutorial? I looked briefly online, but all I could find was non-interactive textbooks or simple pages (still useful though!) That let you match a string to a pattern so you can see that it matches / captures / etc. d.

+56
regex
Jan 24 '09 at 21:50
source share
9 answers

A site written by @wchung, RegexOne, seems to be the perfect answer to the original question. Check this out first;)

The txt2re tool, as commentators have already noted, is very ugly. RegExr (ht @runrunraygun) is a much more beautiful tool for editing regular expressions, although it has completely different functionality and is still not a tutorial.

The main reason why this can be useful for learning regular expressions is the ability to see the effect that each edit has on matching.

Original answer:

I always thought txt2re was a very smart tool. You simply type an example of some text that you want to combine, and then it allows you to select a bit to match. I would find this a pretty useful tool for learning regular expressions.

+33
Jan 24 '09 at 22:49
source share

Shameless plugin: I wrote an online regular expression tutorial ( RegexOne ) over the weekend to help my friends learn regular expressions. They mentioned that real-time examples seemed to help too.

+58
Sep 09 2018-11-11T00:
source share

This is not an interactive, but a good tutorial: www.regular-expressions.info . You can try combining this tutorial with one of the RegEx online tools to try examples (for a little interactivity :-)

+4
Jan 24 '09 at 23:57
source share

It is not online, however you may like the game RegexExpress (warning: one of the award photos is nsfw). This is a game made during the PyWeek contest that teaches you to use regex on an interface like curses. I had a lot of fun.

+3
Jan 26 '09 at 3:14
source share

There is a Regex Hero . This is not a textbook, but an interactive one. It will highlight matches as you type. Highlighting the moment makes it easy to experiment.

+2
May 18 '09 at 17:49
source share
+2
Mar 24 '10 at 18:25
source share

Expressions is an interactive regular expression tutorial. The emphasis is on using features in combination and providing excellent feedback for common mistakes. (Check out my blog post about how we find out that errors are indeed common .)

+2
Jan 29 '13 at 17:09
source share

HiFi Tester Regex

Regular expressions can be a pain. This tool is designed to help developers learn, practice and compose regular expressions.

Although this tool is not quite a tutorial in the style of this SQL website, its purpose is to teach regular expression.

+1
Jun 23 '10 at 17:19
source share

I like http://rubular.com to be interactive and friendly.

0
Aug 30 2018-12-12T00:
source share



All Articles