Java Programming: & vs &&

Status
You're currently viewing only OneFootsTheSame's posts. Click here to go back to viewing the entire thread.
Not open for further replies.

OneFootsTheSame

Smack-Fu Master, in training
70
wb wrote:
For the anal retentive, this is how true and false are properly represented

false == 0
true = !false

And for the truely anal, in Java booleans are a primitive type, are either "true" or "false", and only booleans can be compared. So the statement "false == 0" is incorrect syntactically and also because a specific VM could use 0 for true and still correctly implement the language.
 
Status
You're currently viewing only OneFootsTheSame's posts. Click here to go back to viewing the entire thread.
Not open for further replies.