Given array of n integers. Move all maximum elements to the end of the array without changing the order of others.
First line contains positive integer n. Next line contains n integers. All numbers do not exceed 100 by absolute value.
Print the elements of updated array.