[프로그래머스] 주사위의 개수 (javascript)

몽슈뜨·2023년 1월 15일
0

programmers

목록 보기
54/62
post-thumbnail


🎯나의 풀이

function solution(box, n) {
    let answer = box.map(x => Math.floor(x / n))
    return answer.reduce((a,b) =>  a* b );
}
profile
개발자되면 맥북사줄께

0개의 댓글