Ad
  • Custom User Avatar

    Use long double in the function get_number only. Then your solution will work in most cases. It is hard to implement get_number correctly in general. It is better to use built-in functions like strtod.

  • Default User Avatar

    Hi, please remember to use a spoiler flag when posting code (I have added the flag). For your code, take note of the comment given in the solution set-up:

    // return must be an allocated string to be freed by the tester