Merged
Conversation
TonyKim9401
reviewed
Dec 21, 2024
| */ | ||
| var climbStairs = function (n) { | ||
| // n+1 배열을 만들고 0으로 초기화 | ||
| const dp = new Array(n + 1).fill(0); |
Contributor
There was a problem hiding this comment.
배열 선언에서 .fill(0) 부분은 없어도 괜찮지 않을까 궁금합니다!
Contributor
Author
There was a problem hiding this comment.
정수가 들어갈 자리라서 미리 0으로 초기화했었는데 안해도 상관은 없을거같긴 합니다.
한번 찾아보겠습니다!
TonyKim9401
reviewed
Dec 21, 2024
| }; | ||
|
|
||
| // Map을 사용해서 데이터 최신화 | ||
| let count = new Map(); |
Contributor
There was a problem hiding this comment.
map 대신 알파벳 만큼인 26짜리 배열 하나만을 사용해서 풀이하는 방법도 있을것 같아요!
TonyKim9401
approved these changes
Dec 21, 2024
Contributor
TonyKim9401
left a comment
There was a problem hiding this comment.
2주차 문제풀이 고생 많으셨습니다!
문제에 따라서 최적화 과정을 설명과 함께 적어주셔서 이해하는데 더 도움이 된 것 같아요.
3주차도 파이팅입니다!
Contributor
|
리뷰로 도움드리진 못했습니다만, 3주차도 같이 화이팅 하면 좋을것 같습니다..! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
답안 제출 문제
체크 리스트
In Review로 설정해주세요.