今天就学习课程吧!
今天就开通帐号,24,700 门业界名师课程任您挑!
Solution: Print only those lines consisting of a complete HTML entity - Linux教程
课程: AWK Essential Training
Solution: Print only those lines consisting of a complete HTML entity
(upbeat music) - [Instructor] The challenge in this case is to print from an HTML file only lines that consist of complete HTML entities, that is lines that begin with an HTML tag and end with the corresponding closing tag. This is one possible solution. In the begin section, we set the field separator to a regular expression which consists of a single character which is either an opening or a closing angle bracket. Let me show you the effect that this has on an HTML line. This line begins with the <li> and ends with the </li>. With the field separator, bracket, angle bracket, angle bracket, bracket which specifies a single character, which is either an opening or a closing angle bracket, the number of fields in this case is nine. The first one is an empty field which is the no characters that exist between the beginning of the line and the opening angle bracket. The second field is the li. The third field, this is a. Fourth…
随堂练习,边学边练
下载课堂讲义。学练结合,紧跟进度,轻松巩固知识。