#include <stdio.h>
#include <string.h>
char * strdel(const char * tstring, char * trez)
{ char *ptr;
 strcpy(trez,tstring);
 while((ptr=strstr(trez,"  "))!=NULL)
 strcpy(ptr,ptr+1);
 return trez;}

int main(int, char**)
{char st[40],st2[40],*ptr2;
puts("input string : world and space");
gets(st);
puts("isxodnaya stroka");
puts(st);
strdel(st,st2);
puts("Result string 1");
puts(st2);
printf("Result string 2:\n");
ptr2=new char [40];
puts(strdel(st,ptr2));
    return 0;
}
