Table of Contents
Create a file with .c as suffix, e.g., mine.c and place in it the following C program.
/* this is a comment */
#include <stdio.h> /* bring in I/O library */
main ( )
{
int i;
i = 8;
i = i + 1;
printf("This is a C program. %d\n", i);
}
To compile and link using GNU's C compiler, type:
hostname{~}% gcc mine.c -o mineTo run:
hostname{~}% mine