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
- Recursion
- Developer
- 동적계획법
- Queue
- 2D Array
- indices
- lastIndex
- Poll
- 코틀린
- 프로그래머스
- heap
- report
- Kotlin
- intarray
- dynamic programming
- Util
- booleanarray
- dp
- contentToString
- foreach
- PriorityQueue
- GREEDY
- solution
- Main
- 알고리즘
- 2020
- Java
- sortedBy
- programmers
- hackerrank
Archives
- Today
- Total
목록타겟넘버 (1)
Code in

프로그래머스 깊이/너비 우선 탐색 타깃 넘버 문제입니다. IntelliJ에서의 풀이입니다. val numbers: IntArray = intArrayOf(1, 1, 1, 1, 1) val target: Int = 3 fun solution(numbers: IntArray, target: Int): Int { val arr: ArrayList = ArrayList() recursion(0, numbers, numbers[0], target, arr) recursion(0, numbers, numbers[0]*-1, target, arr) return arr.size } fun recursion(curIndex: Int, numbers: IntArray, curNum: Int, target: Int, arr..
알고리즘 스터디_문제풀이
2020. 8. 25. 13:46