prev

Hello World

next

Very simple program to write output to the screen.  (Located in hello_world.c)
     #include <stdio.h>
     
     /* the main C function */
     int main (int argc, char** argv) {
         printf("Hello world\n");
         return(0);
     }

To compile this application using GCC.
cc -o hello_world hello_world.c
If you want GCC to print warnings for any possible problems add the -Wall flag to the compilation
cc -Wall -o hello_world hello_world.c
To execute this application
./hello_world