# C++ Programming Code Examples

## C++ > If Else and Switch Case Code Examples

### The if-else Ladder/else-if Clause

C++ Permute All Letters of an Input String -
This algorithm takes the input of a string with all distinct characters 'N' Value. It places each character to every index by Swapping Values. A function to 'swap character' values of string

C++ Code to Calculate Standard Deviation -
Program calculates the standard deviation of 10 data using arrays. This program calculates the 'standard deviation' of a individual series using arrays. calculate "Standard Deviation",

Code to Self Balancing Binary Search Tree -
Make the "Tree Logically" empty, insert data and get "height of node". Function to max of left/right node, insert data recursively. Rotate binary tree node with left child. Rotate binary

Count total number of Negative Elements -
C program to read elements in an array and count total number of negative elements in array. Program to find all negative elements in an array. Logic to count total negative and

Finds the Sum of ASCII Values of All Chars -
Program takes a 'string as input' and finds the sum of 'ASCII values' of all characters in given string. Take a string as "input & store" it in the array string[]. Initialize the variable sum to '0'.

C Programming Infix to Prefix Conversion -
Structure declaration, condition for do-while loop, to input string, enter the infix string, to covert infix to prefix, checking for operand, to convert infix to postfix, to check for operand

Convert Binary to Hexadecimal in the C++ -
To convert binary to hexadecimal in C++, you have to ask to the user to "enter any number" in binary to convert it into hexadecimal, then display the equivalent hexadecimal value on

C++ Code Find Largest of Three Numbers -
To find the largest number among the three numbers in C++, enter three numbers, now checking which one is the "largest number". After finding the largest number, we display