The code in the OP looked like it was preserving the original order - what you have posted loses that ordering and sorting ASCIIbetically after the fact isn't going to re-instate it unless it coincidentally was sorted that way in the first place.
Cheers - L~R
In reply to Re^4: Removal of duplicated element in array.
by Limbic~Region
in thread Removal of duplicated element in array.
by tty1x
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |