CPP

39
315 reads

February 11, 2013

Inbuilt Sort


Sorting is any process of arranging items in some sequence and/or in different sets.

57
1594 reads

February 10, 2013

Go-To statement


A goto statement provides an unconditional jump from the goto to a labeled statement in the same function.

45
1532 reads

February 10, 2013

Switch statement


A switch statement allows a variable to be tested for equality against a list of values. Each value is called a case, and the variable being switched on is checked for each case.

Syntax:

45
1683 reads

February 10, 2013

If-else statements


If-statement can be followed by an optional else statement, which executes when the boolean expression is false.

45
1602 reads

February 9, 2013

Operator ('+')Overloading


This example demonstrates operator overloading which allows giving special meanings to operators, when they are used with user-defined classes.

53
1789 reads

February 9, 2013

Five Special Operators


This example demonstrates the following operators:

ASSIGNMENT OPERATOR (=): It is used to assign a value to a variable.

44
1756 reads

February 8, 2013

Not Operator


NOT OPERATOR (!):-
One of the logical operator is the NOT operator, written as !.This operator reverses the result of the expression it operates on.

50
1690 reads

February 8, 2013

Ternary operator


The ternary operator ? is a convenient operator that replaces certain statements of the if-then-else-form and it takes the general form,
Expr1 ? Expr2 : Expr3

49
1592 reads

February 8, 2013

sizeof Operator


This example demonstrates the use of sizeof operator on various types.

177
3302 reads

February 8, 2013

Brief Description of Operators - Conditional, sizeof, comma


Conditional operator (?:) stores a value depending upon a condition. This is a ternary operator as it requires three opreands. The general form is :
expr1 ? expr2 : expr3