-
-
Notifications
You must be signed in to change notification settings - Fork 195
[YoungSeok-Choi] week 3 solutions #1262
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
Conversation
week 2로 보입니다. |
valid-anagram/YoungSeok-Choi.java
Outdated
for(char c: s.toCharArray()) { | ||
if(sMap.containsKey(c)) { | ||
int cnt = sMap.get(c); | ||
sMap.put(c, cnt + 1); | ||
} else { | ||
sMap.put(c, 1); | ||
} | ||
} | ||
|
||
for(char c: t.toCharArray()) { | ||
if(tMap.containsKey(c)) { | ||
int cnt = tMap.get(c); | ||
tMap.put(c, cnt + 1); | ||
} else { | ||
tMap.put(c, 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.
for (int i = 0; i < s.length(); i++) {
이렇게 하고 한번 순회할때 양쪽 다 체크하면 o(n)에서 끝날수있을것 같네요.
n!=m인 경우는 이미 처음에 false로 리턴하니까요.
week 2 작업들이 아직 어프를 받지 못해 Merge가 되지 못한 상황이라 diff가 잡히는 현상입니다..! |
안녕하세요! 먼저 approve가 늦어서 죄송합니다 :( 제가 개인적으로 급한일이 생겨서 머지가 되더라도 이따가 저녁에 코드는 살펴보고 리뷰 남기도록하겠습니다. |
혹시.. 아래의 PR에 대한 승인을 해주실 수 있을까요!! |
7d4ca1b
to
0a28c5f
Compare
답안 제출 문제
작성자 체크 리스트
In Review
로 설정해주세요.검토자 체크 리스트
Important
본인 답안 제출 뿐만 아니라 다른 분 PR 하나 이상을 반드시 검토를 해주셔야 합니다!