반응형
Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
Tags
- 백준
- 자바스크립트
- 타입 챌린지
- 문자열
- Node.js
- 쉬운 문제
- Algorithm
- TCP
- HTTP 완벽 가이드
- 프로그래머스
- 소켓
- BFS
- Crawling
- dfs
- 타입스크립트
- 레벨 1
- 가천대
- ip
- dp
- 수학
- 알고리즘
- 프로그래머스 레벨 2
- type challenge
- Nestjs
- 크롤링
- 그래프
- HTTP
- javascript
- typescript
- socket
Archives
- Today
- Total
목록문자열 내 마음대로 정렬하기 (1)
kakasoo
[node.js] 문자열 내 마음대로 정렬하기 ( 프로그래머스 레벨1 )
// 프로그래머스 level1 문자열 내 마음대로 정렬하기를 풀었습니다. function solution(strings, n) { var answer = []; answer = strings.sort().sort(function(string1, string2) { if (string1[n] > string2[n]) return 1; if (string1[n] < string2[n]) return -1; return 0; }); return answer; }
프로그래밍/알고리즘 풀이
2021. 6. 25. 17:16