Topic: Greedy Algorithm Problem / Level: beginner

Problem: Find the minimum number of steps to make all elements in an array equal, where you can only increment or decrement elements.

Run the code to see the output here...