문제 : https://www.acmicpc.net/problem/1799 오답 (최초코드)아래의 방식으로 풀이 시, 체스말이 서로 잡을 수 없는 위치하는 것은 맞다.하지만, 체스말이 최대의 개수로 존재하는 것은 아니다.#include #include using namespace std; int n; int map[10][10]; int res[10][10] = { 0 }; bool func_check(int y, int x) { for (int i = y, j = x; i >= 0; i--, j--) { // 북서 if (res[i][j] != 0) return false; } for (int i = y, j = x; i >= 0; i--, j++) { // 북동 if (res[i][j] != 0) r..
알고리즘/(깨짐)
2017. 3. 8. 00:08
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
링크
TAG
- FEED
- DP
- C++
- 백준
- listview
- WPF
- 데이터 바인딩
- Custom Cell
- 문자열
- 생활코딩
- BFS
- BOJ
- Grid
- UIView Animation
- 스택
- CollectionView
- XAML
- Add TapGesture
- command
- MVVM
- 코딩야학
- CustomCollectionViewCell
- Fakebook
- 타일링
- dfs
- Cell Animation
- 객체
- 그래프
- 백준온라인
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 | 29 |
30 | 31 |
글 보관함