The Full Wiki

More info on Erlang Programming/Using regexp

Erlang Programming/Using regexp: Wikis


Note: Many of our articles have direct quotes from sources you can cite, within the Wikipedia article! This article doesn't yet, but we're working on it! See more info or our list of citable articles.


Up to date as of January 23, 2010

From Wikibooks, the open-content textbooks collection

< Erlang Programming

Regular Expressions

2> regexp:match("hello world","w.+d").

The regular expression, "w.+d" matches the string, "hello world" at location 7 for 5 chars.

9> regexp:sub("10203040","([2-4]0)+","01").

Makes a substitution, replacing "203040" with "01".


Got something to say? Make a comment.
Your name
Your email address