Jump to content

Bug? or Misunderstanding?


bear
 Share

Recommended Posts

First of all, why are you comparing a number to a string? Second, the behavior is expected. The string is promoted to a number. Since the string itself is not a number, it becomes "0". Therefore, zero is compared to zero which is of course true.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...