# C Programming Code Examples

## C > Strings Code Examples

### Program to count number of vowels and consonants using switch case

C Language Coding Print Alphabets a to z -
Internally C represent every character using ASCII character code. ASCII is a fixed integer value for each global printable, non-printable characters. For example ASCII value of a=97,

Randomized Primality Testings Algorithm -
Method that implements the basic primality test. If witness doesn't return 1, n is definitely composite. Do this by computing a^i (mod n) and looking for "non-trivial" square roots of 1

Find Sum of Natural Numbers While Loop -
The "Positive Numbers" 1, 2, 3... are known as natural numbers. The C program codes below takes a positive integer ( let say n ) as an input from the user and calculates the sum up to n.

C Program Find Day when a Date is given -
Don't U know that there is no month greater than 12. Enter valid month Once again enter the Date Month Year. Fool, Invalid date in February of non leap year. The maximum...

C++ Check if a Point lies Inside or Outside -
'C++ Program' to Check if a Point d lies inside or outside a circle defined by Points a, b, c in a 'Plane'. For any point t (xt, yt) on the plane, its position with respect to the circle defined

Code Perform Binary Search use Recursion -
C program, 'using recursion', performs binary search. In this c program, an array of random number is generated. User is asked to enter a key. The array of random numbers are sorted

Program Code to Reverse a Stack without -
C program, using iteration, reverses a stack content. Stack here is represented using a linked list. A linked list is an ordered set of data elements, each containing a link to its

Open Read Write and Close operation in C -
C file operations: Open, read, write and close operation in C. The fclose( ) function is used for closing an opened file. As argument you must provide a pointer to the file that you...