203. Remove Linked List Elements
题目
Remove all elements from a linked list of integers that have value val.
Example :
Input: 1->2->6->3->4->5->6, val = 6
Output: 1->2->3->4->5
题目大意
删除链表中所有指定值的结点。
解题思路
按照题意做即可。
Type | Name | Latest commit message | Commit time |
---|---|---|---|
.. | |||
Failed to load latest commit information. | |||
![]() |
203. Remove Linked List Elements.go | ||
![]() |
203. Remove Linked List Elements_test.go | ||
![]() |
README.md |
Remove all elements from a linked list of integers that have value val.
Example :
Input: 1->2->6->3->4->5->6, val = 6
Output: 1->2->3->4->5
删除链表中所有指定值的结点。
按照题意做即可。