Skip to content

Conversation

njngwn
Copy link
Contributor

@njngwn njngwn commented Oct 18, 2025

답안 제출 문제

작성자 체크 리스트

  • Projects의 오른쪽 버튼(▼)을 눌러 확장한 뒤, Week를 현재 주차로 설정해주세요.
  • 문제를 모두 푸시면 프로젝트에서 StatusIn Review로 설정해주세요.
  • 코드 검토자 1분 이상으로부터 승인을 받으셨다면 PR을 병합해주세요.

검토자 체크 리스트

Important

본인 답안 제출 뿐만 아니라 다른 분 PR 하나 이상을 반드시 검토를 해주셔야 합니다!

  • 바로 이전에 올라온 PR에 본인을 코드 리뷰어로 추가해주세요.
  • 본인이 검토해야하는 PR의 답안 코드에 피드백을 주세요.
  • 토요일 전까지 PR을 병합할 수 있도록 승인해주세요.

Copy link
Contributor

@TonyKim9401 TonyKim9401 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

13주차 문제 풀이 고생하셨습니다!
풀이중 어려운 부분은 없으셨는지 아이디어는 잘 떠오르셨는지 궁금하네요.
뭐든 좋으니 의견을 PR에 함께 올려주시면 리뷰하는데 많은 도움이 될 것 같습니다.
앞으로 남은 단 2주 마무리 잘 하시고 유종의 미를 거두시길 바랍니다.
파이팅입니다!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

정렬 후 바로 전,후 시간만 간단하게 비교하는 부분이 너무 잘 구현된것 같아요!

@TonyKim9401 TonyKim9401 merged commit 4234f4f into DaleStudy:main Oct 19, 2025
1 check passed
@github-project-automation github-project-automation bot moved this from Solving to Completed in 리트코드 스터디 5기 Oct 19, 2025
@yhkee0404 yhkee0404 self-requested a review October 19, 2025 16:10
Copy link
Contributor

@yhkee0404 yhkee0404 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

코드가 깔끔하네요! 체크리스트 토글해 주셔도 좋을 것 같습니다. 수고하셨습니다!

*/
class Solution {
int cnt = 0;
int result = 0;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

다음에 제안한 조기 종료를 위해 Sentinel Value로 변경합니다.

Suggested change
int result = 0;
int result = -1;

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

아 그렇군요!! 하나 배워갑니다! 피드백 감사드려요☺️☺️

result = node.val;
return;
}
if (node.right != null) traverseInOrder(node.right);
Copy link
Contributor

@yhkee0404 yhkee0404 Oct 19, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이렇게 하면 가지치기 가능할 것 같아요!

Suggested change
if (node.right != null) traverseInOrder(node.right);
if (result == -1 && node.right != null) traverseInOrder(node.right);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: Completed

Development

Successfully merging this pull request may close these issues.

3 participants