Ad
  • Custom User Avatar

    Because unlike addition, multiplication converts string to number before multiplying e.g. '2' * '3' = 6

  • Custom User Avatar

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

  • Custom User Avatar

    Sneaky way to ensure the response is a boolean, instead of null.

  • Custom User Avatar

    A negative zero doesn't make mathematical sense. Normally zero has no sign whatsoever. It is neither negative nor positive. That is why most programming languages also don't have negative zeros.

    There are however a few programming languages that do have negative zeros in some cases. But they are more the exception.

    I am sure google can tell you more about it.

    The kata description also says this:

    Zero (0) is not checked for any specific sign. Negative zeros make no mathematical sense.