Ad
  • Default User Avatar

    Best practice does not necessarily mean the same thing as most performant, many people (myself included) will have marked it best practice for its readability and intelligent use of standard library features.

  • Custom User Avatar

    Yes it is, because it's shown in the homepage otherwise.

  • Default User Avatar

    Oh my bad,thanks for the heads up! But, is it needed even in this part?

    Because here we have the solutions being displayed already.

  • Custom User Avatar

    Please mark your posts as having spoiler content when they do.

  • Default User Avatar

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

  • Default User Avatar

    I'm new to programming and if I'm wrong please someone correct me!

    I believe it's because it's being considered to be null terminated strings.
    Therefore the last character of these strings are '\0', but in a empty string this would be the only character
    and when we compare it with a string that isn't empty it would return true since '\0' is present in both.

    But as far as I understand it isn't something that will be printed in the screen, just something that will be
    considered by the machine.