내일배움캠프/TIL19 [TIL] 07.03 2024. 7. 3. [TIL] 07.01 https://1chanhue1.tistory.com/60오늘의 알고리즘 코드카타 문제 [프로그래머스 kotlin] 롤케이크 자르기시간 초과 발생 코드 fun solution(topping: IntArray): Int { var count=0 for(i in topping.indices){ val set1 = mutableSetOf() val set2 = mutableSetOf() for(j in 0.. i){ set1.add(topping[j]) } for(k in i+1 until topping.size){ set2.add(topping[k]) }1chanhue1.tistory.com 2024. 7. 1. [TIL] 06.27 https://1chanhue1.tistory.com/57 [프로그래머스 , kotlin] 피로도연결리스트를 이용한 풀이 ( 스택과 같은 기능으로)fun solution_ff(k: Int, dungeons: Array): Int { val stack = mutableListOf(Triple(k, 0, BooleanArray(dungeons.size))) var maxCount = 0 while (stack.isNotEmpty()) { val (currentK, count, vis1chanhue1.tistory.com 2024. 6. 27. [TIL] 06.26 https://1chanhue1.tistory.com/55 [프로그래머스 kotlin] 프로세스문제 설명운영체제의 역할 중 하나는 컴퓨터 시스템의 자원을 효율적으로 관리하는 것입니다. 이 문제에서는 운영체제가 다음 규칙에 따라 프로세스를 관리할 경우 특정 프로세스가 몇 번째로1chanhue1.tistory.com 2024. 6. 26. 이전 1 2 3 4 5 다음