请输入您要查询的俚语:

 

俚语 regular expression
释义

regular expression

A text string pattern matching mechanism. Usually applied to individual lines of text, such as from a simple text file, where the regular expression (sometimes abbreviated as RE) pattern can be used to precisely specify which lines ought to match and which shouldn't. The more complicated REs may look very confusing to people who don't know them, as they look more like a random string of letters and other characters without any obvious meaning.

Commonly they're enclosed between slashes (/like this/), because that's how they were used in many ancient Unix tools. They can also be used for text substitution, for example with the s/ construct. A common operator specifying that a RE will follow is the tilde (~).

The Perl language makes heavy use of regular expressions, and the grep tool also searches by REs. SED and AWK are some older tools also using REs.

REs come in two forms: Basic REs and Extended REs, varying slightly in syntax and possible contructs. Perl extens the Extended REs even further and has defined the standard "Perl Compatible REs" (PCRE).
"some example string" =~ /^s*.*e+.*(?:x.* )?.*?g$/
result: 1 (because the regular expression between the // matches the string)

Regular expression

An expression which is just regular, not special, emotionless, but true.
/(Regular) (expression)/ is a /$1 $2/.
See regular expression for a proper use.

Today, the sun is shining, it is a sunny day today!

Butterfly is an insect.

True is not false.

Beautiful flowers have short lives.
随便看

 

英语俚语辞典收录了3210630条英语俚语在线翻译词条,基本涵盖了全部常用英语俚语的翻译及用法,是英语学习的有利工具。

 

Copyright © 2000-2023 Newdu.com.com All Rights Reserved
更新时间:2024/11/8 0:40:25