A small question..
Posted: Fri Feb 21, 2003 2:15 pm
Hi,
I am new to php, just started.. i was trying this:
$var1=3;
$var2 = 3.0;
if(var1==var2)
print "true";
else
print "false";
if (var1===var2)
print "true1";
else
print "false";
the tutorial says == just checks the equality, so doesnt that mean the first test should return a true ?? but the answer is false in both tests. Please explain.
Thanks
I am new to php, just started.. i was trying this:
$var1=3;
$var2 = 3.0;
if(var1==var2)
print "true";
else
print "false";
if (var1===var2)
print "true1";
else
print "false";
the tutorial says == just checks the equality, so doesnt that mean the first test should return a true ?? but the answer is false in both tests. Please explain.
Thanks