mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-01-10 18:48:13 +08:00
22 lines
560 B
HTML
22 lines
560 B
HTML
<p>给定一个头节点为 <code>head</code> 的链表用于记录一系列核心肌群训练项目编号,请查找并返回倒数第 <code>cnt</code> 个训练项目编号。</p>
|
||
|
||
<p> </p>
|
||
|
||
<p><strong>示例 1:</strong></p>
|
||
|
||
<pre>
|
||
<strong>输入:</strong>head = [2,4,7,8], cnt = 1
|
||
<strong>输出:</strong>8</pre>
|
||
|
||
<p> </p>
|
||
|
||
<p><strong>提示:</strong></p>
|
||
|
||
<ul>
|
||
<li><code>1 <= head.length <= 100</code></li>
|
||
<li><code>0 <= head[i] <= 100</code></li>
|
||
<li><code>1 <= cnt <= head.length</code></li>
|
||
</ul>
|
||
|
||
<p> </p>
|