Rules for C++ Programs :-
- C++ program should be in proper sequence.
- Always C++ programs starts with main() function.
- The Body of a function is surrounded by curly brackets.
- C++ Program should be included the header files.
- Variable Declaration should by properly.
- The program statements should be properly placed.
- Every C++ program statement should be terminated by semicolon.
For Example :-
Code
#include <iostream.h>Code
void main()
{
cout<< "welcome Sharad";
}

Join the conversation! Your thoughts help the community grow.