Simple question. It's just interesting if there is something that you can learn from this piece of code or not.
This is found in some outdated code ... I have never seen it before, can not find anything about it on the Internet, and the developer has long been gone.
if ($row['cnt']+0 !== $count+0) {
// log warnings etc
}
My hunch ... no, actually I don’t know why zeros are added to variables before comparison. Any ideas?
Thank you for sharing your thoughts.
source
share