Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
🔎 문제 소개
🖊️ 풀이
N-Queen을 풀면서 대각선을 어떻게 처리해줘야 할지 감이 안잡혀서 직관적으로 반복문 돌리면서 대각선 마킹을 했었는데, "열의 차와 행의 차가 같으면 대각선에 놓여있다" 라는 개념을 알게 되었습니다.
만약 이 풀이에서 알게된 개념을 적용하게 되면 2차원 배열을 사용하지 않아도 되어서 메모리를 아낄 수 있을 것 같습니다.