3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function x($v){ $argv[1] = $v; echo strlen((explode('.',$t=trim('-'==($_=$argv[1])[0]?$n=$_=trim($_,'-'):$_,0)))[1]).($t!==$_?($n?' -':' ').$t:''); echo "\n"; } x('-12.32');
based on 1fFHI
Output for 7.0.0 - 7.2.0
2
Output for 5.3.22 - 5.6.28
Parse error: syntax error, unexpected '[' in /in/pV6I9 on line 6
Process exited with code 255.