C Hello World Program

Share

C hello world program :- c programming language code to print hello world. This program prints hello world, printf function is used to display text on screen, ‘n’ places cursor on the beginning of next line, stdio.h header file contains declaration of printf function. The code will work on all operating systems may be it’s Linux, Mac or any other and compilers. To learn a programming language you must start writing programs in it and may be your first c code while learning programming.

C Hello World Example :

#include <stdio.h>

int main()
{
  printf("Hello worldn");
  return 0;
}


Hello World Program In C :

#include <stdio.h>

int main()
{
  char string[] = "Hello World";

  printf("%sn", string);

  return 0;
}
Share

Tags: , , ,