Java solution beats 100%
ApproachSimple and easy approach first iterate through all numbers and then check digitSum of each number using modulo operator and compare using Math.min funct


# Approach
Simple and easy approach first iterate through all numbers and then check digitSum of each number using modulo operator and compare using Math.min function return min value 


# Code
```java []
class Solution {
    public int minElement(int[] nums) {
        int min = Integer.MAX_VALUE;
        
         for(int num : nums){
            int digitSum = 0; // reset digitSum for each no.
            while(num>0){
                digitSum = digitSum + num%10;
                num = num/10;
            }

            min = Math.min(min, digitSum);
         }
         return min ;
    }
}
```
['Java']