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

[ganu] Week6 #886

Merged
merged 5 commits into from
Jan 17, 2025
Merged

[ganu] Week6 #886

merged 5 commits into from
Jan 17, 2025

Conversation

gwbaik9717
Copy link
Contributor

@gwbaik9717 gwbaik9717 commented Jan 12, 2025

답안 제출 문제

체크 리스트

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

@gwbaik9717 gwbaik9717 requested a review from gmlwls96 January 12, 2025 03:52
@gwbaik9717 gwbaik9717 self-assigned this Jan 12, 2025
@gwbaik9717 gwbaik9717 requested a review from a team as a code owner January 12, 2025 03:52
@github-actions github-actions bot added the js label Jan 12, 2025
Copy link
Contributor

@HC-kang HC-kang left a comment

Choose a reason for hiding this comment

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

@gwbaik9717 님, 6주차도 고생하셨습니다~
매번 느끼지만 정말 깔끔한 풀이라서 리뷰할 부분이 거의 없네요 👍
복잡도에 대한 질문이 하나 있지만, 우선 승인 드리겠습니다!

@@ -0,0 +1,52 @@
// n: height of matrix, m: width of matrix
// Time complexity: O(n*m)
// Space complexity: O(n+m)
Copy link
Contributor

Choose a reason for hiding this comment

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

혹시 공간복잡도를 이렇게 판단하신 이유가 있으실까요?
answer 배열을 포함하셨다면 O(n*m)이 되어야 할 것 같고, 제외한다면 O(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.

말씀해주신 것처럼 answer 배열을 포함을 해서 O(n*m) 으로 판단하였습니다! 어디까지 공간 복잡도로 포함시켜야할지 기준이 약간 모호하다 느껴서요, 현재 저는 input 을 제외한 나머지를 모두 공간 복잡도에 포함시키고 있습니다.

Copy link
Contributor

Choose a reason for hiding this comment

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

아하 그렇다면 Space complexity를 O(n+m)로 기입해주신 부분은 오타일까요..?!

@gwbaik9717 gwbaik9717 merged commit 817f6f0 into DaleStudy:main Jan 17, 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