I have an array which is like this:
$x = array("15","15","18","18","18","18","12","12");
then I want to get the unique values, which results in an array with unique values but with keys not reordered. What should I do? I want to avoid putting it in a loop.