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

[이지민] - 항체 인식, 토마토, 우체국, 문자열 게임 2 #224

Merged
merged 4 commits into from
Mar 16, 2024

Conversation

jeeminimini
Copy link
Member

📌 from issue #220 📌

📋문제 목록📋

항체 인식: ✅
토마토: ✅ 
문자열 게임: ✅ 
우체국: ⛔️

@jeeminimini jeeminimini self-assigned this Mar 16, 2024
Copy link
Member

@soopeach soopeach left a comment

Choose a reason for hiding this comment

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

고생하셨습니다..!!

Comment on lines +25 to +29
for i in range(26):
if len(alphabet[i]) >= k:
for j in range(0, len(alphabet[i]) - k + 1):
mini = min(mini, alphabet[i][j + k - 1] - alphabet[i][j] + 1)
maxi = max(maxi, alphabet[i][j + k - 1] - alphabet[i][j] + 1)
Copy link
Member

Choose a reason for hiding this comment

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

와 깔끔하군요,,,

Comment on lines +26 to +31
for i in range(n):
if abs(people - (total - people - town[i][1])) < mini:
mini = abs(people - (total - people - town[i][1]))
result = town[i][0]

people += town[i][1]
Copy link
Member

Choose a reason for hiding this comment

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

직접 푸신게,,, 대단하십니다.

Comment on lines +28 to +32
for i in range(4):
if 0 <= nx + dx[i] < n and 0 <= ny + dy[i] < m:
if tomato[nx + dx[i]][ny + dy[i]] == 0:
queue.append([nx + dx[i], ny + dy[i]])
tomato[nx + dx[i]][ny + dy[i]] = tomato[nx][ny] + 1
Copy link
Member

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(w) - 1):
alphabet[ord(w[i]) - ord('a')].append(i)

mini = 10_001
Copy link
Contributor

Choose a reason for hiding this comment

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

지미니미니 ㅎㅎ

mini = 1_000_000_000 * 100_000
result = -1
for i in range(n):
if abs(people - (total - people - town[i][1])) < mini:
Copy link
Contributor

Choose a reason for hiding this comment

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

저도 제 식이 뭔지 이해가 안갔었는데 지민님 설명 듣고 이해가 됐습니다 ㅎㅎ

Comment on lines +44 to +45
if after[nx][ny] != update:
possible = -1
Copy link
Contributor

Choose a reason for hiding this comment

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

헉..큐에 넣기 전에 before가 탐색중인 값인지도 조건에 추가하면 after가 다를때 바로 NO처리가 가능하군요...예외처리 댑악

Comment on lines +27 to +28
if abs(people - (total - people - town[i][1])) < mini:
mini = abs(people - (total - people - town[i][1]))
Copy link
Member

Choose a reason for hiding this comment

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

저랑 구현을 다르게 하셔서 좋았습니다!

Comment on lines +66 to +67
if result <= 1 :
print("YES")
Copy link
Member

Choose a reason for hiding this comment

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

resturn 된 possible 의 합으로 처리하는 부분이 좋았습니다

@jeeminimini jeeminimini merged commit bb9aff2 into main Mar 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants