Skip to content

Commit

Permalink
2차원으로 만들기
Browse files Browse the repository at this point in the history
  • Loading branch information
dudwns committed Apr 28, 2023
1 parent c1fe913 commit fa11c7a
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Programmers/exam63.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
function solution(num_list, n) {
var answer = [];
for (let i = 0; i < num_list.length; i += n) {
answer.push(num_list.slice(i, i + n));
}
return answer;
}

0 comments on commit fa11c7a

Please sign in to comment.