3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $a = new DateTime(); $b = new DateTime('+5 minutes'); print_r(array_unique([$a->format('u'), $b->format('u')]));
based on aW1Us
Output for 7.3.0alpha1
Array ( [0] => 003159 [1] => 003180 )
Output for 7.2.6
Array ( [0] => 002047 [1] => 002064 )
Output for 7.2.5
Array ( [0] => 003573 [1] => 003602 )
Output for 7.2.0
Array ( [0] => 003436 [1] => 003451 )
Output for 7.1.7
Array ( [0] => 002404 [1] => 002415 )
Output for 7.1.6
Array ( [0] => 012412 [1] => 012434 )
Output for 7.1.5
Array ( [0] => 007932 [1] => 007949 )
Output for 7.1.0
Array ( [0] => 003993 [1] => 004003 )
Output for 5.4.0 - 7.0.20
Array ( [0] => 000000 )
Output for 4.4.2 - 4.4.9, 5.1.0 - 5.3.29
Parse error: syntax error, unexpected '[', expecting ')' in /in/iBvuo on line 6
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1, 5.0.0 - 5.0.5
Parse error: parse error, unexpected '[', expecting ')' in /in/iBvuo on line 6
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error, expecting `')'' in /in/iBvuo on line 6
Process exited with code 255.