Skip to content

Conversation

ijlijijij
Copy link
Contributor

@ijlijijij ijlijijij commented Oct 4, 2024

답안 제출 문제

Longest Consecutive Sequence 파일 위치가 잘못되어 있어서 수정 하였습니다!

체크 리스트

  • PR을 프로젝트에 추가하고 Week를 현재 주차로 설정해주세요.
  • 바로 앞에 PR을 열어주신 분을 코드 검토자로 지정해주세요.
  • 문제를 모두 푸시면 프로젝트에서 Status를 In Review로 설정해주세요.
  • 코드 검토자 1분 이상으로부터 승인을 받으셨다면 PR을 병합해주세요.

@ijlijijij ijlijijij requested a review from gitsunmin October 4, 2024 08:37
@ijlijijij ijlijijij self-assigned this Oct 4, 2024
@ijlijijij ijlijijij marked this pull request as ready for review October 4, 2024 08:51
@ijlijijij ijlijijij requested a review from a team as a code owner October 4, 2024 08:51
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.

@kjb512 님 이번 한 주도 고생 많으셨습니다!

@@ -0,0 +1,17 @@
# 시간복잡도: O(N)
# 공간복잡도: O(N)
class Solution:
Copy link
Contributor

@HC-kang HC-kang Oct 6, 2024

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.

제가 저번에 폴더를 착각해서 혼동을 드렸네요..

n = len(text1)
lcs = [0]*n
longest = 0
for ch in text2:
Copy link
Contributor

Choose a reason for hiding this comment

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

text2가 길어지는 경우 문제가 되지 않을까 싶었는데 잘 작동하네요
text2 전체 순회보다는 set등으로 중복 순회를 줄일 수 있지 않을까요?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

set을 어떻게 사용할 수 있나요??

}
return a;
}
}
Copy link
Contributor

Choose a reason for hiding this comment

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

궁금해서 찾아보았는데, 이 문제는 오히려 파이썬의 풀이가 Mask를 써야해서 더 복잡해질 수 있나보네요

물론 과거 스터디 풀이중에 이런게 있는걸 보고 두번 놀랐습니다

class Solution:
    def getSum(self, a: int, b: int) -> int:
        return add(a,b)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

넵 자바나 c++를 사용하는게 더 간편해 보여서 자바를 사용했습니다!

저도 리트코드에서 궁금해서 + 연산으로 제출해봤는데 제출이 되더라구요 ㅋㅋㅋㅋ

하지만, 문제 의도가 비트 연산인것같아서 오랜만에 공부했습니다 ㅋㅋㅋ

@ijlijijij ijlijijij merged commit 3889d5e into DaleStudy:main Oct 6, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Status: Completed
Development

Successfully merging this pull request may close these issues.

2 participants