public int solution(int[] a, int[] b) { return IntStream.range(0, a.length) .map(i -> a[i] * b[i]) .sum(); }
출처:https://school.programmers.co.kr/learn/courses/30/lessons/70128