Wap To Print The Reverse Of A Given String
#include<stdio.h>
#include<conio.h> #include<string.h> void main() { char ch[50]; int i,len ; clrscr(); printf("\n enter a string:"); gets(ch); len=strlen(ch); printf("\n the string in the reverse order :"); for(i=len-1;i>=0;i--) printf("%c",ch[i]); getch(); } |