Ad
  • Default User Avatar

    I added a requirement checking that the long was less than or equal to 9999999999999999 and returning false if otherwise. Afterward, more of the tests were failing. could have been my own implementation issues. In any case, I ended up fixing my function as per your earlier help and it passed everything.

  • Default User Avatar

    Yep. fixed it. misread the description. all my bad. Thanks!

  • Custom User Avatar

    For 2121, digits are 2,1,2,1 and after multiplication, they are 4,1,4,1.
    For even lengths, multiplication starts from the leftmost digit. its even presented in examples.

  • Custom User Avatar

    I checked tests and they do not generate numbers longer than 16 digits. Why do you think they do? Do you have any example of such input?

  • Default User Avatar

    Another issue while coding in C:
    It says that inputs are positive integers of up to 16 digits, but when I try to
    test to see that there are 16 digits or less, I am not passing more of the tests
    than before because they are attempting to test integers longer than 16 digits.

  • Default User Avatar

    In testing, it has 2121, expected true.
    but, even amount of digits, so we double starting with the first:
    2, 2, 2, 2 are remaining. sum is 8. It is not a valid number.

    I am coding in C.