Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I usually don't point this out, but:

Come, let us go down and confuse their language so they will not understand each other.

Like the issue with RegEx, its probably better to use nice English words in code to describe a problem solution, so that other people can understand it faster (before they get demotivated).



English words don't solve the real difficulty with Regex's; mathematical regular expressions; or parsers. Describing state machines to do accurately and precisely what we want, though easier than writing an optimizing compiler, is usually non-trivial.

The amazing thing about Regex's is that they make describing some state machines easy.


English is a common base. Not everyone understands Regex or enough about math. If you use Regex, some people might not be able to understand and change your Regex if necessary.

Well, most of the time, no one else needs to understand it ...


Is calling '*' "Kleene_Star" a marked improvement?

The hard part of regular expressions is envisioning the languages they accept. It's not primarily a difficulty with notation as with the concepts the notation encodes.


The * or Kleene star describes a sequence of values from a specific set. A nice function name would be "many", like in Haskell's Parsec. In comparison between *, "Kleene_Star" and "many" is the meaning of the function, when named "many", is easy to imply without consulting the docs.


It's a quote from the story of the Tower of Babel, in the Bible. https://www.biblegateway.com/passage/?search=Genesis%2011&ve... (Verse 7)


Thats why I usually don't point this out. Some people could get infected or something.


Oh man, I totally misunderstood your comment. Never mind!




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: