Home Segments Index Top Previous Next

33: Mainline

On Dos systems, you compile and link programs a little differently. Assuming that your program is in a file named average.c, you produce executable code as follows:

cc -o average.exe average.c 

The file name average.exe appears, instead of average, because Dos, by convention, requires files containing executable C code to have an exe extension.