일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- Node.js
- Nestjs
- type challenge
- 쉬운 문제
- 알고리즘
- 소켓
- TCP
- typescript
- BFS
- 자바스크립트
- 타입 챌린지
- HTTP 완벽 가이드
- javascript
- Algorithm
- 그래프
- Crawling
- 레벨 1
- 타입스크립트
- socket
- 문자열
- 수학
- dfs
- 프로그래머스 레벨 2
- 프로그래머스
- 크롤링
- ip
- 백준
- HTTP
- dp
- 가천대
- Today
- Total
목록백준 1182번 (2)
kakasoo
// 백준 1182번 부분 수열의 합을 풀었습니다. const readline = require("readline"); const rl = readline.createInterface({ input: process.stdin, output: process.stdout, }); const combinations = function* (elements, selectNumber) { for (let i = 0; i < elements.length; i++) { if (selectNumber === 1) { yield [elements[i]]; } else { const fixed = elements[i]; const rest = elements.slice(i + 1); for (const a of combin..
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 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 #include using namespace std; int n, s, sum, counted; int arr[21]; bool visited[21]; void dfs (int start) { visited[start] = true; int cur = start; sum += arr[start]; if (sum == s) { counted++; } for (int i = start + 1; i > n >> s; for (int i = 0; i > arr[i]; for (i..