반응형
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
- 문자열
- 백준
- 알고리즘
- TCP
- Crawling
- javascript
- Algorithm
- 가천대
- 자바스크립트
- typescript
- 수학
- 타입스크립트
- HTTP 완벽 가이드
- dfs
- 소켓
- socket
- 타입 챌린지
- 쉬운 문제
- dp
- 레벨 1
- type challenge
- 크롤링
- 프로그래머스 레벨 2
- BFS
- HTTP
- 프로그래머스
- Node.js
- Nestjs
- ip
- 그래프
Archives
- Today
- Total
목록구조분해할당 (1)
kakasoo

// 프로그래머스 레벨1 핸드폰 번호 가리기를 풀었습니다. function solution(phone_number) { let a, b, c, d, e; let arr = ([a, b, c, d, ...e] = phone_number.split("").reverse()); return [e.map((el) => "*").join(""), d, c, b, a].join(""); } 구조분해할당과 나머지 연산자를 이용하면 쉽게 가능해진다.
프로그래밍/알고리즘 풀이
2021. 6. 28. 15:37