Move Negative Elements in the Array to one side

Description

  • An array contains both positive and negative numbers in random order. Rearrange the array elements so that all negative numbers appear before all positive numbers.

Constraints

Code