title: Awkward comparison of functions in PHP
body: <p>So I've got this snippet:</p>
  
  <pre><code>function compare1($s1, $s2)
  {
      return $s1===$s2;
  }
  
  function compare2($s1, $s2)
  {
      return !strcmp($s1, $s2);
  }
  
  function challenge($s1, $s2) //Objective: return TRUE
  {
      return compare1($s1, $s2) ^ compare2($s1, $s2);
  }
  </code></pre>
  
  <p>What's requested from me is to supply/append/assign values to the $s1 and $s2 variables so as for the last function to return TRUE.</p>
  
  <p>I've tried nearly everything I could think of, like <code>$s1='1' and $s2=1</code> which does return TRUE: </p>
  
  <blockquote>
    <p>var_dump(compare1('1', 1) ^ compare2('1', 1)); //output: int 1</p>
  </blockquote>
  
  <p>Creator of the challenge told me that I shouldn't or rather can't assign integer values to the variables but issue is that no boolean variations worked. Here is the website I'm talking about so as you can see if you could possibly come up with a solution: <a href="http://securitytraps.no-ip.org/challs/strcmp/" rel="nofollow">http://securitytraps.no-ip.org/challs/strcmp/</a></p>
  
  <p>Thanks in advance :)</p>