⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 0581-0582.html

📁 linux-unix130.linux.and.unix.ebooks130 linux and unix ebookslinuxLearning Linux - Collection of 12 E
💻 HTML
字号:


<HTML

<HEAD>

<TITLE>Developer.com - Online Reference Library - 0672311739:RED HAT LINUX 2ND EDITION:gawk Programming</TITLE>

<META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">
<SCRIPT>
<!--
function displayWindow(url, width, height) {
        var Win = window.open(url,"displayWindow",'width=' + width +
',height=' + height + ',resizable=1,scrollbars=yes');
}
//-->
</SCRIPT>
</HEAD>

 -->




<!-- ISBN=0672311739 //-->

<!-- TITLE=RED HAT LINUX 2ND EDITION //-->

<!-- AUTHOR=DAVID PITTS ET AL //-->

<!-- PUBLISHER=MACMILLAN //-->

<!-- IMPRINT=SAMS PUBLISHING //-->

<!-- PUBLICATION DATE=1998 //-->

<!-- CHAPTER=27 //-->

<!-- PAGES=0545-0582 //-->

<!-- UNASSIGNED1 //-->

<!-- UNASSIGNED2 //-->









<P><CENTER>

<a href="0578-0580.html">Previous</A> | <a href="../ewtoc.html">Table of Contents</A> | <a href="../ch28/0583-0586.html">Next</A>

</CENTER></P>



<A NAME="PAGENUM-581"><P>Page 581</P></A>



<!-- CODE //-->

<PRE>

   printf(&quot;this is a second line of the header\n&quot;)  &gt; &quot;report.txt&quot;;

}



This is the header for page 1

this is a second line of the header

the page number is now 0

</PRE>

<!-- END CODE //-->













<P>The output is the same as that of Listing 27.6 except that the output shows up on the

printer instead of the screen. Before printing the file, you have to

close it.

</P>









<H3><A NAME="ch27_ 50">

Summary

</A></H3>









<P>This chapter provides you an introduction to the

awk programming language and the GNU awk: gawk. It is a very powerful and useful language that enables you to search for data,

extract data from files, create commands on-the-fly, or even create entire programs.

</P>









<P>It is very useful as a prototyping language&#151;you can create reports very quickly. After

showing them to the user, changes can be made quickly also. Although it is less efficient than the

comparable program written in C, it is not so inefficient that you cannot create production

programs. If efficiency is a concern with an awk program, it can be converted into C.

</P>









<P>For further information, see the following:

</P>



<BLOCKQUOTE>

Aho, Alfred V., Brian W. Kernighan and Peter J.

Weinberger. The awk Programming<BR>

Language. Reading, Mass.: Addison-Wesley, 1988 (copyright AT&amp;T Bell Lab).<BR>

See also the man pages for gawk on your system.<BR>

GNU awk, gawk, is available on this book's CD-ROM.<BR>

</BLOCKQUOTE>



<A NAME="PAGENUM-582"><P>Page 582</P></A>







</BLOCKQUOTE>









<P><CENTER>

<a href="0578-0580.html">Previous</A> | <a href="../ewtoc.html">Table of Contents</A> | <a href="../ch28/0583-0586.html">Next</A>

</CENTER></P>









</td>
</tr>
</table>

<!-- begin footer information -->





</body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -