-
Notifications
You must be signed in to change notification settings - Fork 0
Week7_SunghunKim #26
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?
Week7_SunghunKim #26
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.
저도 첫번째 방법을 가장 먼저 생각했네요,,, 핵심은 저장 데이터?를 적게 만드는 것 같습니당 이 코드로 중복 검사를 set외에 dictonary를 이용하는 방법 있다는 걸 알게 되었습니다
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.
네 스택 큐 둘다 안쓰고도 되더라구요
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.
딕셔너리는 키로 값을 찾을때 보통 null이 나올 수 있는 자료구조니깐 값을 꺼낼때 조심해야해요
근데 !는 안전하게 값을 꺼내는 방법이 아닌 강제로 꺼내는 방식인데,
앞에 코드에서 딕셔너리에 값을 직접 등록했기 때문에 해당 키 값이 반드시 존재한다고 확신하고 !를 썼습니다.
1. 롤케이크 자르기 - 구현
🔗 문제 링크
https://school.programmers.co.kr/learn/courses/30/lessons/132265
✔️ 소요된 시간
30분
✨ 수도 코드
1차 잘못된 구현
2차 개선
📚 새롭게 알게된 내용
2. 기능개발 - 스택
🔗 문제 링크
https://school.programmers.co.kr/learn/courses/30/lessons/42586
✔️ 소요된 시간
30분
✨ 수도 코드
📚 새롭게 알게된 내용