#include <stdio.h>
#include <stdlib.h>
#include <malloc.h>

struct link{
        int a;
        int b;
        struct link *next;
};

void linked(struct link *);

struct link *start;

void main(void){
        int cnt = 0;
        struct link *temp;

        while(cnt < 10){
                temp = (struct link *)malloc(sizeof(struct link));
                linked(temp);
                cnt++;
        }
}

void linked(struct link *temp){
        
        struct link *te = start;

        if(te == NULL){
                start = temp;
                temp -> next = NULL;
        }
        else{
                while(te -> next != NULL)
                        te = te -> next;

                te -> next = temp;
                te -> next -> next =NULL;
        }
}

링크드 리스트인데~ //

제가 이해를 못해서요~

자세한 설명 부탁드릴꼐요~ __)

잘 부탁드립니다 __)