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)/超级回文数 [super-palindromes].html
2022-03-29 12:43:11 +08:00

27 lines
989 B
HTML
Raw Blame History

This file contains ambiguous Unicode characters

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>现在,给定两个正整数&nbsp;<code>L</code>&nbsp;<code>R</code> (以字符串形式表示),返回包含在范围 <code>[L, R]</code> 中的超级回文数的数目。</p>
<p>&nbsp;</p>
<p><strong>示例:</strong></p>
<pre><strong>输入:</strong>L = &quot;4&quot;, R = &quot;1000&quot;
<strong>输出:</strong>4
<strong>解释:
</strong>49121以及 484 是超级回文数。
注意 676 不是一个超级回文数: 26 * 26 = 676但是 26 不是回文数。</pre>
<p>&nbsp;</p>
<p><strong>提示:</strong></p>
<ol>
<li><code>1 &lt;= len(L) &lt;= 18</code></li>
<li><code>1 &lt;= len(R) &lt;= 18</code></li>
<li><code>L</code>&nbsp;<code>R</code>&nbsp;是表示&nbsp;<code>[1, 10^18)</code>&nbsp;范围的整数的字符串。</li>
<li><code>int(L) &lt;= int(R)</code></li>
</ol>
<p>&nbsp;</p>