1
0
mirror of https://gitee.com/coder-xiaomo/leetcode-problemset synced 2025-09-13 11:21:42 +08:00
Code Issues Projects Releases Wiki Activity GitHub Gitee

add leetcode problem-cn part6

This commit is contained in:
2022-03-27 20:56:26 +08:00
parent c11d601602
commit 08d1f2a596
1096 changed files with 88216 additions and 2 deletions

View File

@@ -0,0 +1,26 @@
<p>给你一个整数 <code>n</code> ,返回 <em>和为 <code>n</code> 的完全平方数的最少数量</em></p>
<p><strong>完全平方数</strong> 是一个整数,其值等于另一个整数的平方;换句话说,其值等于一个整数自乘的积。例如,<code>1</code><code>4</code><code>9</code><code>16</code> 都是完全平方数,而 <code>3</code><code>11</code> 不是。</p>
<p>&nbsp;</p>
<p><strong>示例&nbsp;1</strong></p>
<pre>
<strong>输入:</strong>n = <code>12</code>
<strong>输出:</strong>3
<strong>解释:</strong><code>12 = 4 + 4 + 4</code></pre>
<p><strong>示例 2</strong></p>
<pre>
<strong>输入:</strong>n = <code>13</code>
<strong>输出:</strong>2
<strong>解释:</strong><code>13 = 4 + 9</code></pre>
&nbsp;
<p><strong>提示:</strong></p>
<ul>
<li><code>1 &lt;= n &lt;= 10<sup>4</sup></code></li>
</ul>