0% found this document useful (0 votes)
9 views2 pages

Is Used When We Want To Return The Value of Answer The

The document discusses three key concepts in C++: 1) The #include directive is used to include header files like iostream in a C++ program. 2) If statements allow conditional execution of code using comparison operators like < and >. The code within the curly braces will run if the test condition is true. 3) Functions allow code reuse and organization. The main function is called first and can return an integer or void. Functions are declared with a name, parameters in parentheses, and a return type.

Uploaded by

salman khan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views2 pages

Is Used When We Want To Return The Value of Answer The

The document discusses three key concepts in C++: 1) The #include directive is used to include header files like iostream in a C++ program. 2) If statements allow conditional execution of code using comparison operators like < and >. The code within the curly braces will run if the test condition is true. 3) Functions allow code reuse and organization. The main function is called first and can return an integer or void. Functions are declared with a name, parameters in parentheses, and a return type.

Uploaded by

salman khan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

C++

1: #include <iostream> is pre processer directive which is the FILE


used in program

2: if statement exp ( syntax if (test case)

Body of if statement where the code is run

} )

In if test is given to test the case if test is true then the statement
print or the not

Example

Test in if which are used < (less then test), > (greater then test),

3: FUNCTION

Function is the set of instruction (or to some work)

Exp: main is function of the program which is used in different way like

: int main () is used when we want to return the value of Answer the
statement from computer. int main () will return the int value.

: void main() is used when we don’t want to return value of the


statement form the computer. void main() will return something in
screen.

(Void) (int) (etc) is the type of return.


We can give any name to function like void printsomething().

() this is circle is perimeter

You might also like