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 (English)/第 k 个数(English) [get-kth-magic-number-lcci].html

10 lines
407 B
HTML

<p>Design an algorithm to find the kth number such that the only prime factors are 3, 5, and 7. Note that 3, 5, and 7 do not have to be factors, but it should not have any other prime factors. For example, the first several multiples would be (in order) 1, 3, 5, 7, 9, 15, 21.</p>
<p><strong>Example 1:</strong></p>
<pre>
<strong>Input: </strong>k = 5
<strong>Output: </strong>9
</pre>