Happy Codings - Programming Code Examples
Html Css Web Design Sample Codes CPlusPlus Programming Sample Codes JavaScript Programming Sample Codes C Programming Sample Codes CSharp Programming Sample Codes Java Programming Sample Codes Php Programming Sample Codes Visual Basic Programming Sample Codes


C Programming Code Examples

C > Strings Code Examples

Program 'takes a number' as input and finds a Greater number of the entered number using same digits. Take a number as input. Reverse the number and store it in the array. Using for
Lets take 2 Strings as input and store them in the arrays string1[] and string2[] respectively. "Count the Number" of characters in both the arrays and store the result in the variables co1
Program accepts a string and checks whether a given string is 'Palindrome'. Take a string as input & store it in the array string[]. Store the same string into the another array 'reverse_s'
Check if string is a 'Palindrome' without using the "Built-In function". "Take a string" as input & store it in the array 'string[]'. Then store the same string into the another array 'reverse_s'
C Program 'checks the substring' is present in a given string. Program accepts both string & substring. Then checks whether the substring is present in the string. Enter search substring
The five alphabets 'A, E, I, O and U' are called 'vowels'. All other alphabets except these five vowel letters are called consonants. Program above assumes that the user always enters an
C program code to 'Check whether a String' is palindrome or not without using loop. How to Check whether a string is 'Palindromic String' or not in C. Palindrome string is special string
C program takes the Character value as input and checks whether that character is a vowel or consonant using if-else statement. Since a user allowed to enter an alphabet Lowercase
Program takes two strings as input & checks whether two strings are anagrams. Take two strings as input and store them in the arrays array1[] array2[] respectively. In the function
C program to compare two strings using loop 'Character by Character'. Comparing 2 strings Lexicographically without using string library functions. 'Input two strings' from user. Store
We have to accept '2 Strings' from user using gets and we have to 'Concatenate' these two strings without using library functions. Inside the concate function we are firstly calculating
You can 'concatenate two strings' easily using standard library function strcat() but, in this C program 'concatenates two strings' manually without using 'strcat()' function. Calculate the
In the following program user would be asked to enter 'two Strings' and then the C program would 'concatenate them'. For concatenation we have not used the standard library strcat()
Concatenation of 2 strings is simple copying a string to another. To concatenate two Strings str1 & str2, you will copy all characters of str2 at the end of str1. 'Store it in' a variable str1 &
C program 'Converting string' from lowercase to uppercase string using loop. Internally in C language every characters are represented as an integer value known as ASCII value. Where
Program code to 'convert' uppercase string to lowercase using for loop. First check whether the given character is 'uppercase' alphabet or not. If it is Uppercase Alphabet just add 32 to
Scan a string from "left to right", character by character. In each iteration "copy a character" to a new String variable. As soon as source or original string ends, the process of the coping
C program code to copy one string to another without using inbuilt library function 'strcpy()' Input string and 'store it' to some variable say text1. Declare another variable to 'store copy'
You can use the 'strcpy()' function to copy the content of "one String to another" but, this C Program 'copies the Content' of one string to another manually without "strcpy()" function.
C Program code to 'Count Frequency' of each character in a string Using Loop. There are so many algorithms to Count Frequency of each character. Here I'm explaining the easiest one
Program takes a string as input and count the number of words in the input string. Take the string as input, store it in the array 's[]'. Using for loop search for a space ' ' in the string and
C program to 'count total number' of words in a string using Loop. To count total number of 'Words in a String' we just need to count total number of white spaces. Includes single blank
Program find number of words, blank spaces, Special symbols, Digits, "Vowels" by pointers. We are going to accept string use 'gets()'. We are not using scanf() to accept string because
Program count all occurrences of a character in string using Loop. Input a string, store it in some variable "str". Input character to search occurrences and store it in some variable say
Write a C program to Count Occurrences of a word in a given string using loop. Input string and word from user. Get the total number of occurrences of a word in a string. Print count

Page 1 Page 2 Page 3 Page 4 Page 5