Skip to content

Commit b53d096

Browse files
committed
배열의 원소 길이 / 기초
1 parent 3dc19de commit b53d096

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
function solution(strlist) {
2+
var answer = [];
3+
for(let i=0; i<strlist.length; i++){
4+
answer[i]=strlist[i].length
5+
}
6+
return answer;
7+
}
8+
9+
function solution(strlist) {
10+
return strlist.map(str => str.length);
11+
}

0 commit comments

Comments
 (0)