1) post your code properly and not to a locked pdf document(copy forbidden)
2)
int main() never void!!!
3)
printf("Enter the input string"); not prinft
4) for (i=4;i<
l
{
then you say tmp[i+3]==...
last value of i=l-1 so i+3=l-1+3=l+2
but l=strlen(temp) so last value of temp is temp[l-1]
all this result segmentation fault!
the correct for-->for (i=4;i<
l-3;
i++){
correct these errors,and post properly the new code for the rest.