PHP "riddle"
ZiNgA BuRgA Offline
Fag
*******
Posts: 3,357
Joined: Jan 2008
Post: #1
PHP "riddle"
I'm clearly bored writing this post.
Take this PHP function:

PHP Code:
function test_equality($a, $b, $c) {
    var_dump($a==$b, $a==$c, $b==$c);
}

A certain set of inputs ($a, $b and $c) will cause the function to produce the following output:

Code:
bool(true)
bool(true)
bool(false)


Provide one such sample input to the function.


My Blog
03-10-2011 01:54 PM
Find all posts by this user Quote this message in a reply
Firefox Wins Offline
Member
***
Posts: 164
Joined: Mar 2008
Post: #2
RE: PHP "riddle"
Processing riddle....................................................................
............................................................................................
..............................................................................................
................................................................................................
..................................................................................................
03-12-2011 08:48 PM
Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #3
RE: PHP "riddle"
............... Mmm ... like this?

$a = 0
$b = ''
$c = '0'

03-13-2011 05:09 AM
Find all posts by this user Quote this message in a reply
ZiNgA BuRgA Offline
Fag
*******
Posts: 3,357
Joined: Jan 2008
Post: #4
RE: PHP "riddle"
^ Good job!

My Blog
03-13-2011 09:06 AM
Find all posts by this user Quote this message in a reply

« Next Oldest | Next Newest »

 Standard Tools
Forum Jump: