#include #include #include #define VELIKOST 5000000 int main(void){ char *prochazec,*pamet,*konecpameti; pamet = malloc(VELIKOST); if(pamet == NULL){ printf("problem s mallockem"); return 0; } konecpameti = pamet + fread(pamet, sizeof(char), VELIKOST - 1, stdin); *konecpameti = '\0'; prochazec = pamet; strtok(prochazec,"."); do{ if(strstr(prochazec,"God") != NULL){ printf("%s.\n",prochazec); } } while((prochazec=strtok(NULL,".")) != NULL); free(pamet); return 0; }