3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php echo (NaN == true); echo (NaN === true); echo (NaN == false); echo (NaN == NaN); echo (NaN === NaN);
Output for 7.2.0 - 7.3.0rc4
Warning: Use of undefined constant NaN - assumed 'NaN' (this will throw an Error in a future version of PHP) in /in/7RjEp on line 2 1 Warning: Use of undefined constant NaN - assumed 'NaN' (this will throw an Error in a future version of PHP) in /in/7RjEp on line 3 Warning: Use of undefined constant NaN - assumed 'NaN' (this will throw an Error in a future version of PHP) in /in/7RjEp on line 4 Warning: Use of undefined constant NaN - assumed 'NaN' (this will throw an Error in a future version of PHP) in /in/7RjEp on line 5 Warning: Use of undefined constant NaN - assumed 'NaN' (this will throw an Error in a future version of PHP) in /in/7RjEp on line 5 1 Warning: Use of undefined constant NaN - assumed 'NaN' (this will throw an Error in a future version of PHP) in /in/7RjEp on line 6 Warning: Use of undefined constant NaN - assumed 'NaN' (this will throw an Error in a future version of PHP) in /in/7RjEp on line 6 1
Output for 4.3.0 - 7.1.20
Notice: Use of undefined constant NaN - assumed 'NaN' in /in/7RjEp on line 2 1 Notice: Use of undefined constant NaN - assumed 'NaN' in /in/7RjEp on line 3 Notice: Use of undefined constant NaN - assumed 'NaN' in /in/7RjEp on line 4 Notice: Use of undefined constant NaN - assumed 'NaN' in /in/7RjEp on line 5 Notice: Use of undefined constant NaN - assumed 'NaN' in /in/7RjEp on line 5 1 Notice: Use of undefined constant NaN - assumed 'NaN' in /in/7RjEp on line 6 Notice: Use of undefined constant NaN - assumed 'NaN' in /in/7RjEp on line 6 1