Skip to content

Conversation

@DaleSeo
Copy link
Member

@DaleSeo DaleSeo commented Nov 4, 2025

답안 제출 문제

작성자 체크 리스트

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

검토자 체크 리스트

Important

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

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

@github-actions github-actions bot added the rust label Nov 4, 2025
@DaleSeo DaleSeo changed the title [DaleSeo] WEEK 08 solutions (워크플로우 테스트 중) [DaleSeo] WEEK 08 solutions (워크플로우 테스트 용) Nov 6, 2025
@DaleStudy DaleStudy deleted a comment from dalestudy bot Nov 7, 2025
@DaleStudy DaleStudy deleted a comment from dalestudy bot Nov 7, 2025
@DaleStudy DaleStudy deleted a comment from dalestudy bot Nov 7, 2025
@DaleStudy DaleStudy deleted a comment from dalestudy bot Nov 7, 2025
@DaleStudy DaleStudy deleted a comment from dalestudy bot Nov 7, 2025
@DaleStudy DaleStudy deleted a comment from dalestudy bot Nov 7, 2025
Comment on lines +1 to +2
// TC: O(1)
// SC: O(1)
Copy link
Member Author

Choose a reason for hiding this comment

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

@DaleStudy 복잡도 분석이 정확해?

Copy link
Contributor

Choose a reason for hiding this comment

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

안녕하세요! 새로운 솔루션을 잘 구현하셨네요. 시간 복잡도는 입력 크기(고정된 32비트)에 따라 O(1)로 적절히 표기하셨고, 공간 복잡도도 O(1)로 적합합니다. 가독성도 좋아서 이해하기 쉽고, 주석도 명확하게 달려 있어 좋습니다. 다만, 혹시 더 최적화하거나 다른 방법을 고려한다면, 비트 연산 대신 라이브러리 함수를 사용할 수도 있지만, 이 방식이 가장 직관적이고 효율적입니다. 앞으로도 다양한 접근법을 시도하며 연습하시면 좋겠습니다. 계속해서 좋은 코드 기대할게요!

@DaleStudy DaleStudy deleted a comment from dalestudy bot Nov 7, 2025
@DaleSeo
Copy link
Member Author

DaleSeo commented Nov 7, 2025

@DaleStudy

@dalestudy
Copy link
Contributor

dalestudy bot commented Nov 7, 2025

좋은 시도와 깔끔한 구현에 먼저 박수를 보냅니다! 특히 32비트 정수의 각 비트를 역순으로 뒤집는 문제를 효율적으로 해결하셨네요. 시간복잡도 O(1)과 공간복잡도 O(1)로 적절히 분석하셨고, 명확한 주석도 이해를 돕고 있어 매우 좋습니다.

혹시 더 나은 접근법을 고려한다면, 만약 여러 호출에서 반복적으로 이 함수를 사용한다면, 캐시를 활용하거나, 비트 조작 기법을 더 최적화하는 방법도 생각해 볼 수 있습니다. 하지만 이 문제에서는 현재 방식이 충분히 효율적입니다.

가독성과 스타일 면에서도 특별한 문제는 없어 보입니다. 다만, Rust의 경우 i32의 부호 비트가 고려되어야 하니, 부호가 중요한 문제라면 unsigned 타입을 활용하는 것도 고려해 볼 수 있습니다.

계속해서 좋은 작업 기대하며, 깔끔한 리뷰 감사합니다!

@DaleSeo DaleSeo marked this pull request as ready for review November 16, 2025 18:02
Copy link
Contributor

@dalestudy dalestudy bot left a comment

Choose a reason for hiding this comment

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

현재 주차가 종료되어 자동으로 승인되었습니다. PR을 병합해주세요!

@DaleSeo DaleSeo moved this from Solving to In Review in 리트코드 스터디 6기 Nov 16, 2025
@DaleSeo DaleSeo added this pull request to the merge queue Nov 17, 2025
Merged via the queue into DaleStudy:main with commit 77b83f7 Nov 17, 2025
3 checks passed
@github-project-automation github-project-automation bot moved this from In Review to Completed in 리트코드 스터디 6기 Nov 17, 2025
@DaleSeo DaleSeo changed the title [DaleSeo] WEEK 08 solutions (워크플로우 테스트 용) [DaleSeo] WEEK 08 solutions Nov 17, 2025
@DaleSeo DaleSeo moved this to Completed in 리트코드 스터디 5기 Nov 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

No open projects
Status: Completed

Development

Successfully merging this pull request may close these issues.

1 participant