Ad
  • Custom User Avatar

    you increment i both in the loop construct and in the loop body, which results in the loop skipping past the nul terminator of the string. also, you do not allocate the right amount of memory (why always 10 bytes ?) and you do not nul terminate the returned string either

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution