1
0
mirror of https://gitee.com/coder-xiaomo/leetcode-problemset synced 2025-01-10 18:48:13 +08:00
Code Issues Projects Releases Wiki Activity GitHub Gitee
leetcode-problemset/leetcode-cn/problem (Chinese)/删除中间节点 [delete-middle-node-lcci].html
2022-03-29 12:43:11 +08:00

17 lines
681 B
HTML
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<p>若链表中的某个节点,既不是链表头节点,也不是链表尾节点,则称其为该链表的「中间节点」。</p>
<p>假定已知链表的某一个中间节点,请实现一种算法,将该节点从链表中删除。</p>
<p>例如,传入节点 <code>c</code>(位于单向链表 <code>a->b->c->d->e->f</code> 中),将其删除后,剩余链表为 <code>a->b->d->e->f</code></p>
<p> </p>
<p><strong>示例:</strong></p>
<pre>
<strong>输入:</strong>节点 5 位于单向链表 4->5->1->9 
<strong>输出:</strong>不返回任何数据,从链表中删除传入的节点 5使链表变为 4->1->9
</pre>
<p> </p>