1
0
mirror of https://gitee.com/coder-xiaomo/leetcode-problemset synced 2025-01-27 10:40:26 +08:00
Code Issues Projects Releases Wiki Activity GitHub Gitee
leetcode-problemset/leetcode-cn/problem (Chinese)/训练计划 I [diao-zheng-shu-zu-shun-xu-shi-qi-shu-wei-yu-ou-shu-qian-mian-lcof].html

22 lines
678 B
HTML
Raw Normal View History

2023-12-09 18:53:53 +08:00
<p>教练使用整数数组 <code>actions</code> 记录一系列核心肌群训练项目编号。为增强训练趣味性,需要将所有奇数编号训练项目调整至偶数编号训练项目之前。请将调整后的训练项目编号以 <strong>数组</strong> 形式返回。</p>
<p>&nbsp;</p>
<p><strong>示例 1</strong></p>
<pre>
<strong>输入:</strong>actions = [1,2,3,4,5]
<strong>输出:</strong>[1,3,5,2,4]
<strong>解释:</strong>为正确答案之一</pre>
<p>&nbsp;</p>
<p><strong>提示:</strong></p>
<ul>
<li><code>0 &lt;= actions.length &lt;= 50000</code></li>
<li><code>0 &lt;= actions[i] &lt;= 10000</code></li>
</ul>
<p>&nbsp;</p>