Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
Tags
- 문자열
- 다익스트라
- 투 포인터
- 유니온 파인드
- c++
- Team Fortress 2
- 그리디 알고리즘
- XR Interaction Toolkit
- DFS
- 정렬
- 우선순위 큐
- 백트래킹
- 다이나믹 프로그래밍
- 재귀
- 자료구조
- Unreal Engine 5
- 구현
- 누적 합
- 브루트포스
- 트리
- 유니티
- BFS
- 그래프
- 알고리즘
- 시뮬레이션
- 수학
- 백준
- VR
- 스택
- ue5
Archives
- Today
- Total
목록샤워실 바닥 깔기 (Small) C++ (1)
1일1알

k의 범위가 1~2이기때문에 바닥의 크기는 2 혹은 4이다. 바닥의 크기가 크지 않기 때문에 백트래킹을 이용해서 모든 경우를 탐색하여 문제를 해결하였다. #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; using ll = long long; int dRow[8][2] = { {0,1}, {0,-1} ,{1,1} ,{1,1} ,{0,-1} ,{0,1} ,{-1,-1} ,{-1,-1} }; int dCol[8][2] = { {1,1}, {1,1}, {0,1}, {0,-1}, {-1,-1}, {-1..
알고리즘
2022. 2. 8. 14:04