Ad
  • Custom User Avatar
  • Custom User Avatar

    When counting you ignore case, but when building the result string you don't.
    Also, given == "" is not how you compare strings in C.

  • Custom User Avatar

    In the random tests arr2 is the expected solution, arr is the result of your DuplicateEncoder function.
    !strcmp(arr, arr2) is false if the two don't match.

    I just submitted my solution successfully, and also didn't see an obvious error in the tests.
    If your problem persists, please post your solution here (and make sure to mark it as "having spoiler content").