본문 바로가기
반응형

전체 글311

Leetcode <Tree> 337. House Robber III 49.9% Medium 스터디 문제6번 Tree 정답률 49.9% https://linlaw0229.github.io/2018/06/27/337-House-Robber-III/ 337. House Robber III | linlaw Techblog Problem description: The thief has found himself a new place for his thievery again. There is only one entrance to this area, called the “root.” Besides the root, each house has one and only one parent house. After a tour, the smart thief realized that “al linlaw0229.gith.. 2020. 4. 3.
Leetcode 328. Odd Even Linked List 52.5% Medium 스터디 문제4번 LinkedList 정답률 52.5% https://blog.naver.com/1ilsang/221597552829 LeetCode 328. Odd Even Linked List - LinkedList(in Place) https://leetcode.com/problems/odd-even-linked-list/submissions/링크드 리스트 문제인데, O(1) 의 공간... blog.naver.com class Solution { public ListNode oddEvenList(ListNode head) { ListNode odd = head; if(odd == null) return head; ListNode even = head.next; if(even == null || eve.. 2020. 4. 3.
Leetcode 621. Task Scheduler 47.7% Medium 스터디 문제3번 Queue 정답률 47.7% 2020. 4. 3.
Leetcode <Heap> 264. Ugly Number II 38.9% Medium 스터디 문제2번 Heap 정답률 38.9% https://blog.naver.com/zzang9ha/221771852840 Do it! 자료구조와 함께 배우는 알고리즘 입문 - 자바 6. 정렬 : 힙 정렬(Heap Sort) *** 위 교재로 공부한 내용입니다. ***​힙이란? 힙 정렬(Heap Sort)는 힙을 사용하여 정렬하는 알고리즘... blog.naver.com public class Solution { public int nthUglyNumber(int n) { int result = 1; int array[] = new int[n+1]; int m2 = 0, m3 = 0, m5 = 0; array[0] = 1; for(int i=1; i 2020. 4. 3.
Leetcode 96. Unique Binary Search Trees 50.1% Medium 진짜 재수없는 문제 정답률 50.1% Medium 스터디 Tree 문제5번 백준 34단계정도 http://www.goodtecher.com/leetcode-144-binary-tree-preorder-traversal/ class Solution { public int numTrees(int n) { int[] ans = new int[n+1]; ans[0] = ans[1] = 1; for(int i=2;i 2020. 4. 3.
ArrayList https://blog.naver.com/ks2414e/221723334003 [자바] ArrayList & Vector , Queue(LinkedList), Map에 대해서 알아보자! 하이룽 ~~ 비와영입니다.이번 포스팅은 소개할 녀석들이 많죠??각각 포스팅하자니, 너무 내용이 거기서 거... blog.naver.com https://mainia.tistory.com/2323 [Java] 자바 리스트(List,ArrayList) 이용하는 방법 [Java] 자바 리스트(List,ArrayList) 이용하는 방법 환경 : Eclipse Mars, Android 4.2.2 이번에는 자바 리스트 클래스들에 대해 알아 보겠습니다. 리스트는 배열의 한계 때문에 만들어진 자료형 입니다. 배열을.. mainia.ti.. 2020. 4. 3.
반응형