[Home]
HomePage RecentChanges Frequently Asked Questions

main

Making the application start up from a main routine

In some languages, a '''main''' function provides a program entry point, providing the first user written operations to be performed when the program starts. The awk extraction and reporting language is [[datadriven?]], so does not have a main function. However, it does support the use of [[begin?]] blocks, which can be used to provide us with an initial startup [[block?]] for our application:

 BEGIN {
 # This is our main startup procedure
 print "Hello World!"
 }

Edit this page View other revisions Administration
Last edited 2011年07月18日 09:57 UTC by markhobley

Powered by sdf Creative Commons License <pierre.gaston+awk@gmail.com>

Awk Wiki by #awk is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.

AltStyle によって変換されたページ (->オリジナル) /