Difference between revisions of "Talk:1313: Regex Golf"

Explain xkcd: It's 'cause you're dumb.
Jump to: navigation, search
(Created page with "This is fairly simple fun little one. Regex is sort for regular expressions. A regular expression is a series of characters that denotes a search criteria. For example, you c...")
 
(Added note about punchline panel)
Line 6: Line 6:
  
 
--[[User:Holshy|Holshy]] ([[User talk:Holshy|talk]]) 05:40, 6 January 2014 (UTC)
 
--[[User:Holshy|Holshy]] ([[User talk:Holshy|talk]]) 05:40, 6 January 2014 (UTC)
 +
 +
The last panel includes, of course, a regex "/(meta-)*regex golf/," which represents the phrase "regex golf" preceded by the phrase "meta-" up to ''infinite'' times.
 +
 +
As a punchline, it also refers to Jamie Zawinski's well-known quote about regex,
 +
 +
<blockquote>Some people, when confronted with a problem, think "I know, I'll use regular expressions." Now they have two problems.</blockquote>
 +
 +
Thus, the punchline is that the addition of meta layers to regex golf generates more problems for the programmer, but that was also the setup of the comic. So either the punchline is really weak—worth a chuckle if you got the above two references—or I missed the joke.
 +
[[Special:Contributions/199.27.128.63|199.27.128.63]] 06:22, 6 January 2014 (UTC)

Revision as of 06:22, 6 January 2014

This is fairly simple fun little one.

Regex is sort for regular expressions. A regular expression is a series of characters that denotes a search criteria. For example, you could write a regular expression that would search for anything that looks like an address (a la comic 208).

Regex golf is a game in which you attempt to write a regular expression that will search through a list of items and bring back only those items that meet a certain criteria, but not anything else. The joke is that regular expressions are used to search text, but themselves are text strings. This means that you could write a regular expression that would look for another regular expression. You can then apply ad infinitum, and the universe implodes or something.

--Holshy (talk) 05:40, 6 January 2014 (UTC)

The last panel includes, of course, a regex "/(meta-)*regex golf/," which represents the phrase "regex golf" preceded by the phrase "meta-" up to infinite times.

As a punchline, it also refers to Jamie Zawinski's well-known quote about regex,

Some people, when confronted with a problem, think "I know, I'll use regular expressions." Now they have two problems.

Thus, the punchline is that the addition of meta layers to regex golf generates more problems for the programmer, but that was also the setup of the comic. So either the punchline is really weak—worth a chuckle if you got the above two references—or I missed the joke. 199.27.128.63 06:22, 6 January 2014 (UTC)