Re: It is a math question

Just solve a equation.

```
class Solution {
public int minMoves(int[] nums) {
int min = Integer.MAX_VALUE;
int sum = 0;
for (int num : nums) {
sum += num;
min = Math.min(min, num);
}
int a = sum - (nums.length - 1) * min;
return a - min;
}
}
```