编辑代码

void Insert(Node*head, char name) 
{
    Node* newNode = new Node;
    newNode->name = name;
    newNode->Next = NULL;

    if (!head) {
        head = newNode;
        return;
    }

    Node* abc = head;
    while (abc->next) 
    {
        abc = abc->next;
    }
    abc->next = newNode;
}

void Print(Node * head)
{
Node * temp = head;
for(; temp != NULL; temp=temp->next)
{
printf("%d ", temp->data);
}
}

void Destory(Node *head)                     
{
    Node*p;
    while(h!=NULL)
    {
        p=head->next;
        free(head);
        head=p;
    }
}


int main(void)
{
    char Name[20];
}