|
|
back to boardthere is some bugs in tests in test 11 one or more line has length less then w symbols! please fix it! gets(s[0]); char *p = strtok(s[0], " "); int w = atoi(p); p = strtok(0, " "); int h = atoi(p); if (!(h&1) || !(w&1)) WA(); for (int i = 0; i < h; i++) { gets(s[i]); if (strlen(s[i]) < w) (*(int*)0)++; } Re: there is some bugs in tests Maybe you mean p = strtok(s[0], " "); instead of p = strtok(0, " "); ? Re: there is some bugs in tests no, i mean strtok(0, " ") in case of zero (null) strtok gets last pointer plus position of token |
|
|