목록createList함수 (1)
웅재의 코딩세상
Linked list 구현하기(생성)
singly linked list 구현에 사용되는 데이터 형 enum bool { false, true }; typedef struct _node Node; // 구조체 노드 형명 재지정 struct _node{ //노드 구조체 int data; // 데이터 영역 : int 형 데이터 저장 Node *next; // 포인터 영역 } typedef struct _list{ // linked list 관리 구조체 Node *head; // head pointer ( head node 가리킴 ) Node *tail; // tail pointer ( tail node 가리킴 ) int size; // linked list의 크기 - 실제 data node의 개수 }List; singly linked list 기..
개념/자료구조
2023. 11. 27. 22:06