void main()
{
char a[100];
int i,j,k,l;
clrscr();
printf("ENTER THE STRING: ");
gets(a);
l=strlen(a);
l=l-1;
for(i=0;i<=l;i++)
{
k=a[0];
for(j=0;j
{
a[j]=a[j+1];
}
a[j]=k;
printf("\n%s",a);
}
getch();
}
OUTPUT :
ENTER THE STRING: KAMLESH
HAMLESK
NO OF WORDS ARE 1