3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function barber($type) { echo "You wanted a $type haircut, no problem\n"; } function barber2() { echo "You wanted a haircut, no problem\n"; } call_user_func('barber', "mushroom"); call_user_func('barber', "shave"); call_user_func('barber2', "mushroom"); call_user_func('barber2', "shave");
Output for 4.3.0 - 7.2.0
You wanted a mushroom haircut, no problem You wanted a shave haircut, no problem You wanted a haircut, no problem You wanted a haircut, no problem