Support us on Patreon to keep GamingOnLinux alive. This ensures we have no timed articles and no paywalls. Just good, fresh content! Alternatively, you can donate through PayPal, Flattr, Liberapay or Buy us a Coffee. You can also buy games using our partner links for GOG and Humble Store.

First off, for those readers who aren’t programmers, it’s important to define what are the (in)famous regular expressions. According to the Regex Crossword FAQ…

A regular expression (regex or regexp for short) is a special text string for describing a search pattern. (…) For example, if you wanted to find all references to the name "Casper" but using all the different ways of spelling it, you could use the regular expression [CK]asp[ae]r, which will match both "Casper", "Caspar", "Kasper" and "Kaspar".

The thing is: this definition by no means reflects how insanely difficult it is to learn them. There is no other way than repeatedly using them until you eventually start memorizing them, a process that is particularly arduous and unintuitive. This is what Regex Crossword aims to prevent, by hosting a series of Sudoku-like puzzles to help you master them; it won’t be an easy process still, but at least it may be more fun…

On the left you can see a typical puzzle, in which you must carefully  observe the regexs that represent every row or column, and write a letter from a selected list that matches both criteria. You can always press the "Help" button at the top right of the website to visualize a diagram with all the information you need. As you can see, it’s easy to understand the rules, but hard to master them.

The website features several sections to make the levels as varied as possible. There is also another area which includes levels made by other users, along with a stats page. Also, if you check the Help and FAQ section, you will be recommended other tools and online resources in case you want to learn a bit more about regexs. Don’t forget to use an account so that your progress on the levels can be saved.

Finally, although this project is "something we do for fun", you can donate via PayPal or several cryptocurrencies (check the Help and FAQ section to see which ones are available) to help with hosting expenses and to keep ensuring further improvements and levels.

Visit Regex Crossword via the following link.

Article taken from GamingOnLinux.com.
15 Likes, Who?
We do often include affiliate links to earn us some pennies. We are currently affiliated with GOG, Humble Store and Paradox Interactive. See more here.
About the author -
author picture
The number of available Linux games became so massive that, as a consequence, we reached a point where there are a lot of interesting but overlooked titles waiting to be discovered.

My articles aim to be a small contribution in that sense, by giving these hidden gems some of the exposure they deserve.

[code][/code]
See more from me
15 comments
Page: 1/2»
  Go to:

x_wing 1 April 2020 at 3:46 pm UTC
Really fun!
tomaszg 1 April 2020 at 3:52 pm UTC
Nice. Next step - regex golf! https://xkcd.com/1313/
Purple Library Guy 1 April 2020 at 3:56 pm UTC
Weird. The definition sounds like a straightforward, fairly intuitive thing. What makes them so hard?
x_wing 1 April 2020 at 4:05 pm UTC
Purple Library GuyWeird. The definition sounds like a straightforward, fairly intuitive thing. What makes them so hard?

The infinity combinations you can get and that they aren't easy to read. IMO is one of the most powerful tool for text search but also a dangerous one (the day you create your RE it totally makes sense and it is hyper intuitive... six weeks later you want to cry).
Purple Library Guy 1 April 2020 at 5:28 pm UTC
x_wing
Purple Library GuyWeird. The definition sounds like a straightforward, fairly intuitive thing. What makes them so hard?

The infinity combinations you can get and that they aren't easy to read. IMO is one of the most powerful tool for text search but also a dangerous one (the day you create your RE it totally makes sense and it is hyper intuitive... six weeks later you want to cry).
I see. So the cautionary tale for young programmers is, if you aren't solid in your commenting and variable names, you'll be condemned to use this stuff.
Arehandoro 1 April 2020 at 5:45 pm UTC
Oh man, finally a -hopefully- way to learn better regex!

Purple Library Guy
x_wing
Purple Library GuyWeird. The definition sounds like a straightforward, fairly intuitive thing. What makes them so hard?

The infinity combinations you can get and that they aren't easy to read. IMO is one of the most powerful tool for text search but also a dangerous one (the day you create your RE it totally makes sense and it is hyper intuitive... six weeks later you want to cry).
I see. So the cautionary tale for young programmers is, if you aren't solid in your commenting and variable names, you'll be condemned to use this stuff.

I did some commenting in few regex I had to do at work the other day... and two days later when I revisit them it wouldn't work. Turned out with all the rush to leave the office I had confused some symbols and had messed it xD
Pikolo 1 April 2020 at 6:19 pm UTC
Fun, when you're not tearing your hair out
Anza 1 April 2020 at 6:26 pm UTC
tomaszgNice. Next step - regex golf! https://xkcd.com/1313/

This might have been inspiration for the comic: https://alf.nu/RegexGolf

ArehandoroOh man, finally a -hopefully- way to learn better regex!

Purple Library Guy
x_wing
Purple Library GuyWeird. The definition sounds like a straightforward, fairly intuitive thing. What makes them so hard?

The infinity combinations you can get and that they aren't easy to read. IMO is one of the most powerful tool for text search but also a dangerous one (the day you create your RE it totally makes sense and it is hyper intuitive... six weeks later you want to cry).
I see. So the cautionary tale for young programmers is, if you aren't solid in your commenting and variable names, you'll be condemned to use this stuff.

I did some commenting in few regex I had to do at work the other day... and two days later when I revisit them it wouldn't work. Turned out with all the rush to leave the office I had confused some symbols and had messed it xD

The linked site, https://regex101.com/ is actually nice for situations like that. It parses the regular expression into components and explains what they do.

As for the crossword itself, it's actually doable and I completed almost all the official puzzles, only the hexagonal one is unfinished.
Salvatos 1 April 2020 at 7:28 pm UTC
Purple Library GuyWeird. The definition sounds like a straightforward, fairly intuitive thing. What makes them so hard?
Unlike programming languages, you don’t have meaningful variable or function names to rely on. It’s just symbols and a lot of nesting of rules and patterns. So it’s about a legible as minified code, if not less.

For example, this very simple pattern will match semi-colons that appear at the start or end of a line, or are followed by another semi-colon (I use it to clean up a list after removing duplicate entries):
^;+|;(?=;)|;$

Every single character has significance, a purpose of its own. Namely:
<start of line><semi-colon><1 or more><OR><semi-colon><start of group><look ahead (without including in results)><match><semi-colon><end of group><OR><semi-colon><end of line>

It’s very hard to come up with the exact pattern you are trying to match (without getting false positives), and often as hard to remember what it’s trying to match if you come back to it after the fact. If someone else made it and you don’t even know what it’s looking for, you have to decipher it piece by piece.


Last edited by Salvatos on 1 April 2020 at 7:29 pm UTC
whizse 1 April 2020 at 7:48 pm UTC
Or, as jwz so eloquently put it:

"Some people, when confronted with a problem, think “I know, I'll use regular expressions.” Now they have two problems. "
While you're here, please consider supporting GamingOnLinux on Patreon, Liberapay or Paypal. We have no adverts, no paywalls, no timed exclusive articles. Just good, fresh content. Without your continued support, we simply could not continue!

You can find even more ways to support us on this dedicated page any time. If you already are, thank you!

You need to Register and Login to comment, submit articles and more.


Or login with...

Livestreams & Videos
None currently, submit yours here!
Popular this week
View by Category
Contact
Latest Comments
Latest Forum Posts