Skip to content
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

[mallayon] Week 7 #941

Merged
merged 7 commits into from
Jan 24, 2025
Merged

[mallayon] Week 7 #941

merged 7 commits into from
Jan 24, 2025

Conversation

mmyeon
Copy link
Contributor

@mmyeon mmyeon commented Jan 22, 2025

답안 제출 문제

체크 리스트

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

@mmyeon mmyeon self-assigned this Jan 22, 2025
@mmyeon mmyeon requested a review from a team as a code owner January 22, 2025 09:39
@github-actions github-actions bot added the ts label Jan 22, 2025
@mmyeon mmyeon requested a review from Jay-Mo-99 January 22, 2025 09:40
let start = 0,
end = 0,
maxLength = 0;
const set = new Set<string>();
Copy link
Contributor

Choose a reason for hiding this comment

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

안녕하세요, set을 사용해 중복 문자 처리가 용이한 윈도우 구간을 설정하고, start와 end로 슬라이딩을 구현하신 구조를 잘 봤습니다. 효율적인 풀이 방법이라고 생각합니다. 👍

덧붙여, map을 사용하면 문자와 해당 인덱스를 함께 저장할 수 있어 중복 문자가 발견되었을 때 start를 한 칸씩 이동하는 대신, map에 저장된 인덱스를 참고해 한 번에 점프할 수 있습니다. 현재 풀이도 충분히 잘 작성되었지만, 혹시 다른 방법을 참고하고 싶으실까 해서 남겨봅니다. 고생 많으셨습니다

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@Jay-Mo-99 안녕하세요!
말씀해주신대로 맵에 인덱스 저장하니까, 인덱스 개별로 관리하지 않아도 돼서 로직이 엄청 깔끔해지네요 !!
더 좋은 풀이법 이야기해주셔서 정말 감사합니다 😄
소중한 리뷰 덕분에 많이 배웠습니다! 이번주도 고생 많으셨습니다 !!! 👍

@mmyeon mmyeon merged commit 6d1380b into DaleStudy:main Jan 24, 2025
1 check passed
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