TODAY JAVA SCHOOL

In java school, programming, design, computer general knowledge, web application, software, web services, social media, digital marketing, oops, concept of programming language, oops feature, console media, graphics medium, first programming, c, c ++ , Java, PHP, SQL, MySQL, HTML, HTML_5, J_query, JavaScript, Bootstrap, Framework, images with logos, examples, shared and explained.

https://www.amazon.in/b?node=26373545031&linkCode=ll2&tag=1234567801cdb-21&linkId=3b9882431b00409b44141e0344b35a15&language=en_IN&ref_=as_li_ss_tl

Breaking

Saturday, 2 May 2020

Structure Of C Programming Language | Basic Structure Of C Programming Language | Structure Of C Programming Language With Example

Structure of  C Programming Language


Structure of c program will explain the step of c program in many step a program will developed so there are the step:-

  •          Comment Line
  •             Header file declaration
  •             Main function
  •           Opening barse
  •           Body of program   
  •      Closing barse


download image of structure in c language

     ·       /* Comments */

Comments are a way of explaining what makes a program. The compiler ignores comments and used by others to understand the code.


      ·       #include<stdio.h>      

stdio is standard for input/output, this allows us to use some commands which includes a file called stdio.h. Or This is a preprocessor command. That notifies the compiler to include the header file stdio.h in the program before compiling the source-code.


     ·       int/void main()  

int/void is a return value, which will be explained in a while.


     ·       main()       

The main() is the main function where program execution begins. Every C program must contain only one main function. Or This is the main function, which is the default entry point for every C program and the void in front of it indicates that it does not return a value.


    ·       Braces                                                

Two curly brackets "{...}" are used to group all statements. Or Curly braces which shows how much the main() function has its scope.


       ·       printf()      

It is a function in C, which prints text on the screen. OrThis is another pre-defined function of C which is used to be displayed text string in the screen.


Example:

/* write a program to print hello */

#include<stdio.h>
#include<conio.h>
Void main()
{
printf(“hello sir welcome to today class of c”);
getch();
}


Output:

Hello sir welcome to today class of c


No comments:

Post a Comment