September 1998
Intermediate to advanced
848 pages
20h 13m
English
Before the modern graphical interface, there was the command-line interface. DOS and UNIX are examples. The command line is the line you type to run your program in a command-line environment. Suppose you have a program in a file named fuss. Then the command line to run it might look like this in UNIX:
$ fuss
Or it might look like this in DOS:
C> fuss
Command-line arguments are additional items on the same line.
% fuss -r Ginger
A C program can read those additional items for its own use (see Figure 11.6).
A C program reads these items by using arguments to main(). Listing ...
Read now
Unlock full access