In this example, you will learn how to print "Hello, World!" on the screen using C programming. A "Hello, World!" program is a basic program that displays "Hello, World!" on the screen.
PROGRAM :
#include<stdio.h>
int main()
{
printf("Hello World");
return 0;
}
OUTPUT :
How "Hello, World" program in C works?
The preprocessor command #include instructs the compiler to include the contents of the stdio.h (standard input and output) file in the program.
The stdio.h file contains functions for taking input and displaying output, such as scanf() and print().
The programme will not build if you use the printf() function without including #include<stdio.h>.
A C program's execution begins with the main() function.printf() is a library function that displays formatted output on the screen.
In this software, printf() prints the text Hello, World to the screen.
The return 0; statement represents the program's "Exit status." Simply put, this phrase marks the conclusion of the programme.
Good Good
ReplyDelete