diff --git a/最后一舞/C语言基础进阶合集版编程题.md b/最后一舞/C语言基础进阶合集版编程题.md index 2611d17..01ebc88 100644 --- a/最后一舞/C语言基础进阶合集版编程题.md +++ b/最后一舞/C语言基础进阶合集版编程题.md @@ -851,8 +851,8 @@ int main(){ *(q-strlen(str2))='\0'; p-=strlen(str2); } - if(*p == *str2){ - p--; + if(*q != str2){ + p-= q-str2; } p++; }