[DS] Basic Concepts
1. System Life cycle
1. System Life cycle
트리를 사용해 집합을 표현하기 집합의 원소 : 0, 1, 2, …, n-1 모든 집합은 쌍 별로 분리
5.7.1 Introduction
5.6.1 Heap ADT
tree 의 leaf node 의 NULL link 공간 낭비 → 활용 방법이 없을까? null link 대신 thread 로 대체 ptr→leftChild 가 null 이면 inorder traversal 에서 ptr 이전의 node 를 가리킴. → ...
[Program 5.6] Copying Binary Tree
6가지 순회 방법 존재
5.2.1 ADT
5.1.1 Terminology
[Figure 4.1]
4.4.1 Representing Polynomials As Singly Linked List
Sequential 표현 장점 연속적인 요소들을 고정된 거리를 두고 저장함. 많은 연산에 적용 가능 ex) 배열 int a[10] 등. 단점 ...
Example
여러 스택 & 큐 관리 1개의 stack이나 queue를 가지고 있다면 sequential 표현이 효율적이다. 여러 stack이나 queue가 공존하면, sequential 표현은 효율적이지 않다.
Declarations typedef struct _node { struct _node *llink; element item; struct _node *rlink; } node; typedef node *node_pointer;
4.5.1 Operations For Chains
ADT
ordered list(순차 리스트)의 특수한 형태
ADT
3.6.1 Expressions
미로 표현 - 2차원 배열