# Php Programming Code Examples

## Php > Site Navigation Code Examples

### Navigation through a page-list, which is returned by a Database

C Program to Print Sum of Array Elements - In C, we are setting up the pointer to the base address of array and then we're incrementing pointer and using * operator to get & sum-up the values of all the array elements. Enter the

C++ Program use Linear Search Technique - First ask to enter the array size then it will ask to enter the array elements, then it will finally ask to enter a number to be search in array to check whether it is present in the array or not

C++ Language The Rules of Abstract Class - 1:-) As we have seen that any class that has a pure virtual function is an abstract class. 2:-) We cannot create the "instance" of abstract class. For example: If I have written this line

Getting a User Input as String in The C++ - This can be considered as inefficient method of reading user input, why? Because when we read the user input string using cin then only the "First word of the String" is stored in char

C++ Program Checks Armstrong Number - In c++ program, a positive integer is asked to enter which is stored in the variable origNum. The number is copied to variable num. This is done because we need to check the origNum

C Codes Calculates the Area of a Triangle - This C Program code calculates the area of a triangle given it's three sides. The formula or algorithm used is: Area = sqrt(s(s - a)(s - b)(s - c)), where s = (a + b + c) / 2 or perimeter / 2. &

Search Sorted Sequence Divide & Conquer - Using Fibonacci numbers we calculate mid of data array to search the data item. 'Calculate' the mid of the array. Divide the array into two subarray. 'Compare the item' by mid element

Inputs Few Numbers Performs Merge Sort - C program, using recursion, 'Performs Merge' sort. A Merge Sort is a sorting algorithm with 'Complexity of O(nlogn)'. It is used for sorting numbers, structure, files. Perform Merge Sort