DP World Interview Question

Rearrange array such that elements greater ar towards right and smaller toward left