3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $test = ['a' => 1, 'b' => null]; echo "array_key_exists:\n"; echo array_key_exists('a', $test) ? "a: found\n" : "a: not found\n"; echo array_key_exists('b', $test) ? "b: found\n" : "b: not found\n"; echo "\n\nisset:\n"; echo isset($test['a']) ? "a: found\n" : "a: not found\n"; echo isset($test['b']) ? "b: found\n" : "b: not found\n"; echo "\n\nempty:\n"; echo empty($test['a']) ? "a: found\n" : "a: not found\n"; echo empty($test['b']) ? "b: found\n" : "b: not found\n";
based on QIX0f
Output for 5.5.0 - 7.3.1
array_key_exists: a: found b: found isset: a: found b: not found empty: a: not found b: found