LeetCode 2149 – Rearrange Array Elements by Sign
Solved: Rearrange array with alternating ve and-ve elements
Used two lists to collect positives & negatives
Then merged alternately→O(n) time,O(n) space
Great for understanding order-based array handling!
#LeetCode #ArrayProblems