C Program to Reverse a Word How to write a C Program to Reverse a Word in C Programming Language ? This program reverse a word. Solution For C Program:
Dictionary Word Search C Program How to write a C Program to Find Dictionary Word Search ? Solution For C Program to Find a Word in Dictionary :
C Program To Input & Print More Than One Words In Single Line How to write a C Program To Input & Print More Than One Words In Single Line in C Programming Language ? Solution For C Program : /*C Program To Input & Print More Than One Words In Single Line.*/ #include<stdio.h> #include<conio.h> #include<string.h> void main() { char s1[50]; int len; clrscr(); printf("\nEnter the string:"); scanf("%[^\n]",s1); printf("Output string:%-50s",s1); len=strlen(s1); printf("\nlength of the string =%d",len); getch(); } You may also learn these C Program/Code : C Program To Swap Two Numbers Without Using Third Variable C Program To Understand Use Of Pointers In MATRIX C Program To Write Data In A File And Search Data From File C Program Concatenating Two Strings Into A Third System C Program To Copy One Character Array Into Another C Program To Generating Fibonacci Series Using Recursion C Program To Convert Decimal To Binary Using Recursion C Program to Calculate GCD using recursion C Program To Calculate First Numbers Using Recursion C Program Finding the sum of Squares using Recursion C Program to Find NCR Of A Given Number Program C Program To Check The Given Value Is Vowel C Program To Find Maximum Of Given Numbers C Program To Convert Temperature In Celsius To Fahrenheit, Using Function C Program To Convert Temperature Into Celsius C Program To Find Simple Interest C Program To Find Week Day Of A Given Date C Program To Find The Average Of n Numbers C Program To Display The Number In A Specific Formats C Program To Generate Multiplication Table C Program to Count Number of Lines in Input until Interrupted by CTRL + Z C Program To Print Text Into Uppercase C Program To Reverse A Given Number C Program to Find Factors Of A Given Number C Program To Find GCD Of Two Non-Negetive Numbers C Program to Find The Product Of Two Numbers Without Multiplication Operator C Program to Find Factorial Number C Program to Print ASCII equivalent of a character until terminated by key is ‘x’ C Program Date from string DDDD-DD-DD C Program to Swap two variables without using third variable C Program To Multiply Two Matrices C Program To Print Alphabets Like {Aa Bb Cc...} C Program To Print Alphabets Like {Az By Cx...} C Program To Print Lines Of A Paragraph Having More Than 15 Characters C Program To Print Prime Numbers Upto The Number You Want C Program To Print String In Formatted Output Form C Program To Print Sum Of n Digit Number C Program To Print Table Horizontally C Program To Print Tridiagonal Matrix C Program To Reverse A Number C Program To Reverse The String Using Pointer C Program To Search A Number Inside The Array C Program To Sort An Array In Ascending And Descending Order C Program To Sort An Array Of Names In Alphabetical And Reverse Order C Program To Store Students Record In A Text File C Program To Store Students Record Using Structure C Program To Find LCM and HCF Of Two Number C Program To Find LCM and HCF Of Two Number Using Function C Program to find LCM and HCF Of Two Number Using Recursion C Program To Find Length Of A String Including Blank Spaces, Tabs, And Other Special Characters C Program To Find Length Of String And Concatenate Two Strings C Program To Find Product Of Two No Using MACRO C Program To Find Reverse Of Any Digit Number C Program To Find Sum and Difference Of Two Matrices C Program To Find The Frequency Of A Number C Program To Find The Length, Reverse Of A String And To Check It Is Palindrome or Not C Program To Find The Maximum And Minimum Value In An Array C Program To Find Transpose Of A Matrix C Program To Find Union & Intersection Of Two Array C Program To Implement Heap Sort C Program To Input & Print More Than One Words In Single Line C Program To Make Employee Payment Record Using Structure C Program To Do Basic Arithmetic Calculation
C Program to count number of sentences words and letters in a paragraph How to write a C Program to count number of sentences words and letters in a paragraph in C Programming Language ? This C Program to count number of sentences words and letters in a paragraph. Solution: #include<stdio.h> main() { char ch[150]; int i,c=0,c1=0,c2=0; printf("Enter a Paragraph \n"); gets(ch); for(i=0;ch[i]!='\0';i++) { if(ch[i]=='.'||ch[i]=='!'||ch[i]=='?') { c++; c1++; } else if(ch[i]==' '||ch[i]==',') c1++; else if(ch[i]>65&&ch[i]<123) c2++; } printf("\nNumber of letters = %d \nNumber of words=%d ",c2,c1); printf("\nNumber of Sentences = %d\n",c); }
C Program to Convert Number to Words in C How to write a C Program to Convert Number to words in C Programming Language ? Solution: #include <stdio.h> #include <string.h> int main() { printf("This program will write a integer number in words\n\n(Try to) keep the number less than 10000\n"); int number,i,m,j,temp; char string[2][9]; char ekok[9][6]; int ara[10]; printf("Write a number: (0) to exit "); scanf("%d", &number); while (number>0) { for(i=0; number!=0; i++){ ara[i]=number%10; number=number/10; } m=i; for(i=i-1; i>=2; i--) { if(ara[i]==1) { printf("One "); } else if(ara[i]==2) { printf("Two "); } else if(ara[i]==3) { printf("Three "); } else if(ara[i]==4) { printf("Four "); } else if(ara[i]==5) { printf("Five "); } else if(ara[i]==6) { printf("Six "); } else if(ara[i]==7) { printf("Seven "); } else if(ara[i]==8) { printf("Eight "); } else if(ara[i]==9) { printf("Nine "); } if(i==2 && ara[i]!=0) { printf("Hundred "); } else if (i==3) { printf("Thousand "); } } while(i==1){ if(ara[i]==0) { printf(""); } else if(ara[i]==1) { if(ara[i-1]==0) { printf("Ten"); i--; break; } else if(ara[i-1]==1) { printf("Eleven"); i--; break; } else if(ara[i-1]==2) { printf("Twelve"); i--; break; } else if(ara[i-1]==3) { printf("Thirteen"); i--; break; } else if(ara[i-1]==4) { printf("Fourteen"); i--; break; } else if(ara[i-1]==5) { printf("Fifteen"); i--; break; } else if(ara[i-1]==6) { printf("Sixteen"); i--; break; } else if(ara[i-1]==7) { printf("Seventeen"); i--; break; } else if(ara[i-1]==8) { printf("Eighteen"); i--; break; } else if(ara[i-1]==9) { printf("Nineteen"); i--; break; } } else if(ara[i]==2) { printf("Twenty "); } else if(ara[i]==3) { printf("Thirty "); } else if(ara[i]==4) { printf("Fourty "); } else if(ara[i]==5) { printf("Fifty "); } else if(ara[i]==6) { printf("Sixty "); } else if(ara[i]==7) { printf("Seventy "); } else if(ara[i]==8) { printf("Eighty "); } else if(ara[i]==9) { printf("Ninety "); } i--; } if(ara[i+1]!=1 || m==1) { if(ara[i]==0) { printf(""); } else if(ara[i]==1) { printf("One"); } else if(ara[i]==2) { printf("Two"); } else if(ara[i]==3) { printf("Three"); } else if(ara[i]==4) { printf("Four"); } else if(ara[i]==5) { printf("Five"); } else if(ara[i]==6) { printf("Six"); } else if(ara[i]==7) { printf("Seven"); } else if(ara[i]==8) { printf("Eight"); } else if(ara[i]==9) { printf("Nine"); } } printf("\n"); printf("\nWrite a number: (0) to exit "); scanf("%d", &number); } }