1669. Merge In Between Linked Lists
Medium
You are given two linked lists: list1
and list2
of sizes n
and m
respectively.
Remove list1
's nodes from the ath
node to the bth
node, and put list2
in their place.
The blue edges and nodes in the following figure indicate the result:
Build the result list and return its head.
Example 1:
Example 2:
Constraints:
3 <= list1.length <= 10^4
1 <= a <= b < list1.length - 1
1 <= list2.length <= 10^4
解題
Previous1662. Check If Two String Arrays are EquivalentNext1704. Determine if String Halves Are Alike
Last updated