已知两个链表head1 和head2 各自有序,
19 查阅
参考答案:
Node * Merge(Node *head1 , Node *head2)
\r\n
{
if ( head1 == NULL)
return head2 ;
if ( head2 == NULL)
return head1 ;
Node *head = NULL ;
Node *p1 = NULL;
Node *p2 = NULL;
if ( head1->data < head2-