Skip to content

Conversation

@BaeKwangho
Copy link
Contributor

@BaeKwangho BaeKwangho commented Nov 12, 2025

답안 제출 문제

작성자 체크 리스트

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

검토자 체크 리스트

Important

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

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

Copy link
Contributor

@YuuuuuuYu YuuuuuuYu left a comment

Choose a reason for hiding this comment

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

현재 시간 기준으로 two-sum, house-robber가 커밋되어있는데
PR 내용에는 two-sum 대신 contains-duplicate가 체크되어있습니다

}

return f(0);
}
Copy link
Contributor

Choose a reason for hiding this comment

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

마지막 라인에 개행 문자가 빠져있습니다

Comment on lines 5 to 17
let temp_i = 0;
let temp_j = 0;

for (let i = 0; i < nums.length; i++) {
temp_i = nums[i];
for (let j = i + 1; j < nums.length; j++) {
temp_j = nums[j];

if (temp_i + temp_j === target) {
return [i, j];
}
}
}
Copy link
Contributor

Choose a reason for hiding this comment

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

temp 변수들이 nums[i], nums[j]로 초기화하고 비교만 하는 방식이면
변수 선언 없이 nums만 사용해도 좋을 것 같습니다.

for (let i = 0; i < nums.length; i++) {
  for (let j = i + 1; j < nums.length; j++) {
    if (nums[i] + nums[j] === target) {
      return [i, j];
    }
  }
}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

감사합니다! 반영했습니다

}

return [];
}
Copy link
Contributor

Choose a reason for hiding this comment

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

마지막 라인에 개행 문자가 빠져있습니다

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ci 를 정상통과 하는 것으로 보아, 적용이 되어 있는 것 같습니다. 확인 감사합니다!

Comment on lines +54 to +69
function f(num: number) {
if (resultMap.has(num)) {
return resultMap.get(num);
}

if (nums.length - 1 < num) {
resultMap.set(num, 0);
} else {
const first = nums[num] + f(num + 2);
const second = f(num + 1);

const result = first >= second ? first : second;
resultMap.set(num, result);
}

return resultMap.get(num);
Copy link
Contributor

Choose a reason for hiding this comment

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

제가 파이썬은 잘 모르지만 num 값이 원소보다는 인덱스 용도로 쓰이는거 같은데 맞을까요?
만약 맞다면 직관적인 변수명(index 등)이 좋을 것 같습니다

@BaeKwangho BaeKwangho added this pull request to the merge queue Nov 17, 2025
Merged via the queue into DaleStudy:main with commit e767d99 Nov 17, 2025
1 check passed
@github-project-automation github-project-automation bot moved this from Solving to Completed in 리트코드 스터디 6기 Nov 17, 2025
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.

2 participants