3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $identifier = "a@z.com"; $identifier2 = "another"; echo "Original"; echo "B: " . strpos($identifier, '@') === false ? false : true; echo "B: " . strpos($identifier2, '@') === false ? false : true; echo "<br />"; echo "Improve"; echo "B: " . ((bool) strpos($identifier, '@') !== false); echo "B: " . ((bool) strpos($identifier2, '@') !== false);
Output for 4.3.0 - 7.1.0
Original11<br />ImproveB: 1B: