mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-09-05 15:31:43 +08:00
存量题库数据更新
This commit is contained in:
@@ -3,25 +3,28 @@
|
||||
<p>An integer <code>n</code> is a power of three, if there exists an integer <code>x</code> such that <code>n == 3<sup>x</sup></code>.</p>
|
||||
|
||||
<p> </p>
|
||||
<p><strong>Example 1:</strong></p>
|
||||
<p><strong class="example">Example 1:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>Input:</strong> n = 27
|
||||
<strong>Output:</strong> true
|
||||
<strong>Explanation:</strong> 27 = 3<sup>3</sup>
|
||||
</pre>
|
||||
|
||||
<p><strong>Example 2:</strong></p>
|
||||
<p><strong class="example">Example 2:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>Input:</strong> n = 0
|
||||
<strong>Output:</strong> false
|
||||
<strong>Explanation:</strong> There is no x where 3<sup>x</sup> = 0.
|
||||
</pre>
|
||||
|
||||
<p><strong>Example 3:</strong></p>
|
||||
<p><strong class="example">Example 3:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>Input:</strong> n = 9
|
||||
<strong>Output:</strong> true
|
||||
<strong>Input:</strong> n = -1
|
||||
<strong>Output:</strong> false
|
||||
<strong>Explanation:</strong> There is no x where 3<sup>x</sup> = (-1).
|
||||
</pre>
|
||||
|
||||
<p> </p>
|
||||
|
Reference in New Issue
Block a user