[dolphinflow86] WEEK 05 Solutions#2762
Open
dolphinflow86 wants to merge 1 commit into
Open
Conversation
Contributor
There was a problem hiding this comment.
🏷️ 알고리즘 패턴 분석
- 패턴: Greedy, Two Pointers
- 설명: 최소 가격을 추적하며 현재 가격과의 차이로 이익을 갱신하는 방식으로, 한 번의 순회로 최적 해를 구하는 그리디 패턴에 해당합니다. 또한 가격을 한 방향으로 스캔하며 최대 이익을 계산하므로 투 포인터의 간단한 변형으로 볼 수 있습니다.
📊 시간/공간 복잡도 분석
| 유저 분석 | 실제 분석 | 결과 | |
|---|---|---|---|
| Time | O(N) | O(n) | ✅ |
| Space | O(1) | O(1) | ✅ |
피드백: 초기 최소 가격을 설정하고 가격이 오를 때마다 이익을 갱신하는 단일 순회 방식이다.
개선 제안: 현재 구현이 적절해 보입니다.
Contributor
📊 dolphinflow86 님의 학습 현황이번 주 제출 문제
누적 학습 요약
문제 풀이 현황
🤖 이 댓글은 GitHub App을 통해 자동으로 작성되었습니다. 🔢 API 사용량 (gpt-5-nano)
|
Contributor
|
@dolphinflow86 안녕하세요~ 상태 In Review로 설정되어 있는데 의도하신게 맞는지 확인 부탁드립니다! |
Contributor
Author
안녕하세요! In Review로 된 것은 의도가 맞습니다. 예전에 스터디 가이드쪽에서 미리 PR을 올리고 리뷰를 길게 받으면서 가는게 좋다고 하신걸 본적이 있어서요. In Review로 바꾸는 것은 제가 잘못 봤을수도 있습니다 -> Solving으로 바꿔놓았습니다~ |
Contributor
There was a problem hiding this comment.
깔끔하게 잘 해결해 주셨네요!
best time to buy and sell stock, 즉 해당 문제는
뒤에 로마 숫자를 붙혀서 1, 2, 3, 4, 5 총 다섯종류가 있는데요
dp 연습하기에 정말 괜찮은 문제라고 생각해서
2번문제
II는 한번 풀어보시길 추천드려요!
Contributor
Author
There was a problem hiding this comment.
오! 네 문제 추천 감사합니다! 한번 풀어볼게요 👍
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
답안 제출 문제
작성자 체크 리스트
In Review로 설정해주세요.검토자 체크 리스트
Important
본인 답안 제출 뿐만 아니라 다른 분 PR 하나 이상을 반드시 검토를 해주셔야 합니다!