arunkumar
BAN USERi'm currently doing MS(se) at VIT.
#include<stdio.h>
#include<conio.h>
int main()
{
char s[20]={'a','a','a','a','b','b','b','c','a','a','a','b'};
int i,j,count=1,k=0;
for(i=0;i<strlen(s);i++)
printf("%c",s[i]);
printf("\n");
for(j=0;j<strlen(s);j++)
{
if(s[j]==s[j+1]){
count++;
}
else if(count>1){
k=k+count;
printf("%c%d",s[j],count);
j=k-1;
count=1;
} else if(count==1){
k=k+count;
printf("%c%d",s[j],count);
j=k-1;
count=1;
}
}
getch();
}
Repkylecfarrell, Personnel at Bocada
Property custodian with a reputed organization and help in keeping accurate check over the supplies and inventory of materials and ...
wt abt 36 ??? it wont work..
- arunkumar February 04, 2012