프로그래머스
프로그래머스 - 평균 구하기
thiago6
2019. 1. 9. 16:19
class Solution {
public double solution(int[] arr) {
double answer = 0;
for (int num: arr) {
answer += num;
}
answer /= arr.length;
return answer;
}
}