摘要: 一、正则表达式基础 元字符 描述 . 匹配任何单个字符。例如正则表达式r.t匹配这些字符串:rat、rut、r t,但是不匹配root。 $ 匹配行结束符。例如正则表达式weasel$ 能够匹配字符串"He's a weasel"的末尾,但是不能匹配字符串"They are a bunch of weasels."。 ^ 匹配一行的开始。例如正则表达式^When in能够匹配字符串"When in the course of human events"的开始,但是不能匹配"What and When in the&q 阅读全文
posted @ 2011-07-04 22:19 temptation 阅读(210) 评论(0) 推荐(1) 编辑