fork(2) download
  1. # include <stdio.h>
  2.  
  3. int fuzzyStrcmp(char s[], char t[]){
  4. for(int i=0; i<=99; i++){
  5. if(s[i]!=t[i])
  6. if('A'<=s[i] && s[i]<='Z')
  7. if(s[i]+32!=t[i])
  8. return 0;
  9. }
  10. return 1;
  11. }
  12.  
  13. int main(){
  14. int ans;
  15. char s[100];
  16. char t[100];
  17. scanf("%s %s",s,t);
  18. printf("%s = %s -> ",s,t);
  19. ans = fuzzyStrcmp(s,t);
  20. printf("%d\n",ans);
  21. return 0;
  22. }
  23.  
Success #stdin #stdout 0.01s 5316KB
stdin
abCD AbCd
stdout
abCD = AbCd -> 0