# C Programming Code Examples

## C > Beginners Lab Assignments Code Examples

### find sum of array elements using pointers, recursion & functions

C++ Generating All Subsets of a Given Set -
Program print all the possible combination of each length from the given array in gray code order. The 'time complexity' of this algorithm is 'O(n*(2^n))'. This algorithm takes the input

Code Finding Minimum Number of Edges -
Program to find minimum number of edges to cut to make the 'graph disconnected'. An edge in an undirected connected graph is a bridge if removing it disconnects the graph.

Program Finds Prime Numbers in a Range -
Program should display every prime number between 'range' and at the end total number of "prime numbers" found in range. Separate function which receives "two parameters" for

C Programs Calculates the Value of sin(x) -
C Program Coding to Calculates the Value of sin(x). It's a non-differentiable function. Start at zero, then goes up to 1, then back down to 0. But then, instead of Going Negative, it will

C++ Sample Code Implement Bucket Sort -
Divide the range into equal parts and assign a 'bucket' to each part. Split the data and insert them into the Corresponding bucket by using insertion sort. 'Merge' all the buckets into one

Program Implement Gauss Seidel Method -
This is a "C++ Program" to implement "Gauss Seidel" Method. In numerical Linear Algebra, the Gauss-Seidel method, also known as the Liebmann method or "method of successive"

Code Finds Second Smallest of n Elements -
Linearly traverse the data array. Keep track of the "Smallest Number". Simultaneously keep updating the second smallest number also. A function to calculate second. If array element

Find the Nearest Common Ancestor in The -
C Program prints all the elements of Nth level in single line. Structure of binary tree node. Add node to binary tree. Height of the binary tree. Finds the nearest common ancestor. If