Basic Structure / Parts of C++ Program (Urdu/Hindi)
IT Series IT Series
43.1K subscribers
31,797 views
817

 Published On Aug 4, 2020

In this video, we will learn the basic structure / parts of C++ Program.
A program in C++ consists of the following parts:
• Preprocessor directive
• Main() function
• Program body (C++ statements)
Preprocessor Directives
Preprocessor directives are instructions given to the preprocessor. A program called the preprocessor reads the source code. The preprocessor searches for special lines that begin with the # symbol. These lines contain commands, or directives, that cause the preprocessor to amend or process the source code in some way. The preprocessor directives start with hash symbol #. These directives are written at the start of program. Include preprocessor directive is used to include header files in the program
main( ) Function
The main() function is the starting point of a C++ program. The control enters main() function and starts executing its statements when the program is run. Each program must contain main() function. Any number of statements can be written in the body of the main() function.
The statements of the program are written in curly braces. The curly brace { is called opening brace and } is called closing brace.These statements are collectively known as the body of a program. Each statement in C++ language is terminated by semicolon (;). It is called statement terminator.
Step by step explanation.
Easy to follow and understand.
https://www.itseriestutor.com
  / itseriestutor  
#ITSeriesTutor #CPP #BasicStructure

show more

Share/Embed