Sorting is any process of arranging items in some sequence and/or in different sets.
A goto statement provides an unconditional jump from the goto to a labeled statement in the same function.
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:
If-statement can be followed by an optional else statement, which executes when the boolean expression is false.
This example demonstrates operator overloading which allows giving special meanings to operators, when they are used with user-defined classes.
This example demonstrates the following operators:
ASSIGNMENT OPERATOR (=): It is used to assign a value to a variable.
NOT OPERATOR (!):-
One of the logical operator is the NOT operator, written as !.This operator reverses the result of the expression it operates on.
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
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