#include <stdio.h>
int strlen(char *s){
char *p = s;
while(*p != '\0') p++;
return p - s;
}
void strcpy(char *s, char *t){
while(*s++ = *t++)
;
}
int strcmp(char *s, char *t){
while(*s++ == *t++){
printf("%c, %c\n", s, t);
if(*s == '\0')
return 0;
}
return *s - *t;
}
int main(){
int p;
char s[5] = "hooy";
char t[5];
char *r = "hooz";
printf("%d\n", strcmp(s, r));
scanf("%d", &p);
return 0;
}
I2luY2x1ZGUgPHN0ZGlvLmg+CgppbnQgc3RybGVuKGNoYXIgKnMpewoJY2hhciAqcCA9IHM7Cgl3aGlsZSgqcCAhPSAnXDAnKSBwKys7CglyZXR1cm4gcCAtIHM7Cn0KCnZvaWQgc3RyY3B5KGNoYXIgKnMsIGNoYXIgKnQpewoJd2hpbGUoKnMrKyA9ICp0KyspCgkJOwp9CgppbnQgc3RyY21wKGNoYXIgKnMsIGNoYXIgKnQpewoJd2hpbGUoKnMrKyA9PSAqdCsrKXsKCQlwcmludGYoIiVjLCAlY1xuIiwgcywgdCk7CgkJaWYoKnMgPT0gJ1wwJykKCQkJcmV0dXJuIDA7Cgl9CglyZXR1cm4gKnMgLSAqdDsKfQoKaW50IG1haW4oKXsKCWludCBwOwoJY2hhciBzWzVdID0gImhvb3kiOwoJY2hhciB0WzVdOwoJY2hhciAqciA9ICJob296IjsKCQoJcHJpbnRmKCIlZFxuIiwgc3RyY21wKHMsIHIpKTsKCQoJc2NhbmYoIiVkIiwgJnApOwoJcmV0dXJuIDA7Cn0=