-
Notifications
You must be signed in to change notification settings - Fork 1
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
[Week10] String - 휘 #65
base: main
Are you sure you want to change the base?
Conversation
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.
나머진 저랑 비슷한 것 같아요! 마지막 주차까지 수고많으셨습니다~
# 왼쪽 제거 | ||
temp = word[:l_index] + word[l_index + 1:] | ||
if temp[:] == temp[::-1]: return 1 | ||
# 오른쪽 제거 | ||
temp = word[:r_index] + word[r_index + 1:] |
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.
글자를 삭제해서 푸셨군용!!
|
||
# [6550 부분 문자열](https://www.acmicpc.net/problem/6550) | ||
|
||
> 접근 방법 |
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.
인덱스를 이용한 풀이 잘 봤습니다!
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.
깔끔한 풀이 잘 보고 갑니다!! 10주차까지 고생하셨어요 ✨
read = sys.stdin.readline | ||
|
||
words = [read().rstrip() for _ in range(5)] | ||
words_length = [len(word) for word in words] |
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.
아예 모든 입력의 길이를 저장해놨네요!
ss = read().rstrip() | ||
if not ss: break | ||
s, t = ss.split() | ||
t_index, s_index = 0, 0 |
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.
투 포인터 같이 구현하셨네요!
|
||
|
||
def check_palindrome(word): | ||
if word[:] == word[::-1]: return 0 |
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.
엇 그냥 뒤집으면 되네요!!! 덕분에 좋은 방법 알아가요 👀
No description provided.