일단 나무위키 정보부터 습득해보자.https://ko.wikipedia.org/wiki/%EC%9E%90%EB%A3%8C\_%EA%B5%AC%EC%A1%B0흐름 : 자료구조자료구조(資料構造, 영어: data structure)는 컴퓨터 과학에서 효율적인 접근
자료의 특성과 크기, 주요 사용법과 수행하는 연산의 종류, 구현에 필요한 기억 공간의 크기에 따라 여러 가지 종류의 자료구조 중 하나를 선택할 수 있다.자료구조의 종류로는1\. 자료형에 따라 분류하는 단순 구조2\. 자료 간 관계가 1 대 1인 선형 구조3\. 1 대
Java Onboarding Java는 C++와 마찬가지로 Object Oriented Language이며, 플랫폼에 independent하다. 즉, Write Once, Run Anywhere가 가능하다. Java는 객체지향이므로 모든 것들이 객체화되어있다.
Priority Queue : 다익스트라 알고리즘, Huffman 코딩, Prim 알고리즘 등 다양한 알고리즘에서 활용되는 DS이다. 보통 Queue와 달리 우선순위가 높은 원소가 먼저 나오도록 정렬되어 있다.파이썬에서 제공하는 heapq 클래스는 다음과 같다.heap
\-1^sign x (1.mantissa) x 2^(exponent-bias)\-> 즉, 부호 + 가수(Mantissa) = 지수(Exponent)로 표현한다.1 bit : sign8 bits : exponent, bias=12723 bits : mantissa, 숨겨
위 데이터 타입들은 전부 primitive type이라 불리며, Wrapepr class가 존재한다.자바에서 primitive type은 딱 위의 8개이다.다만, String은 문법적으로는 primitive type처럼 편리하게 쓸 수 있지만, 엄연히 'Object'이
시험이 이틀 뒤인만큼 너무 자료구조 과목과 거리감있는 공부는 지양하기로.. 빠르게 훑고 넘어가자. Array Operators (smooooth operrrration) Arithmetic operators : +, -, *, /, %, ++, -- Relational operators : ==, !=, >, =, >
수행 시간, 메모리로 측정한다.Empirical analysisTheoretical analysis 실제 실행하면서 측정input에 따라 다르다.같은 환경에서 측정해야 비교 가능.Measurement criteria메모리 사용량, 수행 시간이론값Asymptotic b
in java, it is public class Arrays, extending Object.This class also contains a static factory that allows arrays to be viewed as lists.The methods in
데이터와 다음 노드를 가리키는 정보를 갖고 있다.Properties \- 스택, 큐같은 ADT를 구현할 때 사용될 수 있다. \- 삽입, 삭제시 Array처럼 reallocate나 전체 구조를 reorganization할 필요 없이 O(1), constant
LIFOtop에서 삽입, 삭제가 일어남.주로 array나 linked list로 구현됨.Stack class in JAVA : Vector의 subclass ... not very desirable.Mainpush(object) : top에 원소 삽입.Object po
FIFO schemearray나 linked list로 구현한다.front에서 deque(좌측), back(rear)에서 enque(우측)Mainenqueue(Object) : rear(우측)에 추가Object dequeue() : front에서 원소 삭제 및 리턴Ot
Consist of nodes and linkes denoting parent-child relation.Special case of graphs with a hierarchical structure but without loops.Each elemept except
Can be done easily by recursionSo, order of visit does matter\-> 좌, print, 우로 움직이기 때문에 binary tree에서만 유효.\-> Printing Arithmetic Expressions 응용 가능.Pri
Lookup TimeBalanced Tree : O(log n)Unbalanced Tree : O(n)Insertion TimeBalanced Tree : O(log n)Unbalanced Tree : O(n)A Self-balancing binary search tr