>>315 ./a <ソース.c
#include <stdio.h>
int main()
{
  char s[] = "string", b[1024]; /*
string */
  do {
    if(!gets(b)) return 1;
    printf("%d\n", strncmp(b,s,3) ? 1:0);
  } while(strcmp(b, "XXXX"));
  return 0;
}