-
-
Notifications
You must be signed in to change notification settings - Fork 195
[jaejeong1] WEEK 11 Solutions #551
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
reorder-list/jaejeong1.java
Outdated
// 풀이: 역순으로 저장할 스택에 node들을 넣고, 기존 node 1개/스택 node 1개씩 이어 붙인다 | ||
// 스택은 LIFO로 저장되기 때문에, 문제에서 요구하는 순서대로 reorderList를 만들 수 있다 | ||
// TC: O(N) | ||
// SC: O(2N) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
혹시 SC에 O(2N)에서 2가 붙은 이유가 있을까요?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@haklee 기존 ListNode와 새로 생성하는 스택을 모두 더해 2N이라고 표시했는데 기존 ListNode는 원래있던 것이니 N이 맞겠군요..!! 수정했습니다 :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
수고 많으셨습니다! description에는 두 문제만 푼 것으로 되어있지만 실제로는 세 문제를 푼 것으 보이는데 이를 반영하여 description 내용을 수정해주시면 좋을것 같고, invert-binary-tree 풀이 끝에 빈 줄이 없어서 linelint를 통과하지 못한 것으로 보이니 이것도 반영하여 수정해주시면 좋을것 같습니다.
넵! 말씀주신 내용 적용해 업데이트했습니다. 감사합니다!! |
답안 제출 문제
체크 리스트
In Review
로 설정해주세요.