-
Notifications
You must be signed in to change notification settings - Fork 6
[CR] 10월 2, 3주차 #98
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
base: main
Are you sure you want to change the base?
[CR] 10월 2, 3주차 #98
Conversation
blcklamb
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
채정 => 송희
문자열 폭발💣 수고하셨습니다!
| for i in range(len(string)): | ||
| tmp.append(string[i]) | ||
| if tmp[-1] == bomb_str[-1] and len(tmp) >= len(bomb_str): | ||
| if tmp[-len(bomb_str):] == bomb_str: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
조건문 처리할 때 처음에 최대한 조건을 줄여야지 시간이 적게 나올 것 같은데,
송희님께서 하신 부분이 가장 적게 나오네요!(536ms) 흥미로운 지점입니다.
if tmp[-1] == bomb_str[-1]:
if len(tmp) >= len(bomb_str) and tmp[-len(bomb_str):] == bomb_str:
=> 548ms
if tmp[-1] == bomb_str[-1]:
if len(tmp) >= len(bomb_str):
if tmp[-len(bomb_str):] == bomb_str:
=> 580ms
| if tmp: | ||
| print("".join(tmp)) | ||
| else: | ||
| print("FRULA") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
조건문 처리 외에 나머지는 저와 거의 동일합니다!
문제 번호
리뷰어에게
Puyo Puyo랑 모음사전은 @blcklamb 님이,
문자열 폭발은 @Malza0408 님이 해주시면 됩니다...ㅎㅎ
제가 브랜치도 나눠놓고 이전 CR을 제 때 생성 안해서 이렇게 됐네요...
잘 부탁드립니다~!!