3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $test[] = 1253; $test[] = 1253; $test[] = 5342; $test2[] = 1253; $test2[] = 5342; $test2[] = 6478; $final = array_merge($test, $test2); echo '<pre>'; var_dump($final); echo '</pre>'; $final = array_unique($final); echo '<pre>'; var_dump($final); echo '</pre>'; $final = array_unique($final); echo '<pre>'; var_dump($final); echo '</pre>';
based on TrOGV
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
<pre>array(6) { [0]=> int(1253) [1]=> int(1253) [2]=> int(5342) [3]=> int(1253) [4]=> int(5342) [5]=> int(6478) } </pre><pre>array(3) { [0]=> int(1253) [2]=> int(5342) [5]=> int(6478) } </pre><pre>array(3) { [0]=> int(1253) [2]=> int(5342) [5]=> int(6478) } </pre>