#include #include #include int main() { int d=0; char a,*b,*c,*e,*f; b=&a; b=malloc (10000000*sizeof(char)); c=b; if(b==NULL) { printf("ne e"); return 0; } while (scanf("%c",c)==1) c++; *c=0; c=b; c=strstr (c,"God"); //hledame boha while(*c!=10) c--; //hledame tecku pred bohem c++; e=c; //adresa tecky pred bohem while(*c!='.') c++; //hledame tecku za bohem f=c; for(c=e;c<=f;c++) { printf("%c",*c); } printf("\n"); while(c!=NULL) { c=strstr (c,"God"); //hledame boha if(c==NULL) return 0; while(*c!='.') c--; //hledame tecku pred bohem c++; e=c; //adresa tecky pred bohem while(*c!='.') c++; //hledame tecku za bohem f=c; for(c=e;c<=f;c++) { printf("%c",*c); } printf("\n"); } free(b); return 0; }