chore(i8n,learn): processed translations
This commit is contained in:
committed by
Mrugesh Mohapatra
parent
15047f2d90
commit
e5c44a3ae5
@ -1,50 +1,57 @@
|
||||
---
|
||||
id: 5900f3891000cf542c50fe9c
|
||||
title: 问题29:不同的权力
|
||||
title: 'Problem 29: Distinct powers'
|
||||
challengeType: 5
|
||||
videoUrl: ''
|
||||
forumTopicId: 301941
|
||||
dashedName: problem-29-distinct-powers
|
||||
---
|
||||
|
||||
# --description--
|
||||
|
||||
考虑2≤a≤5和2≤b≤5的ab的所有整数组合:
|
||||
Consider all integer combinations of ab for 2 ≤ a ≤ 5 and 2 ≤ b ≤ 5:
|
||||
|
||||
22 = 4、23 = 8、24 = 16、25 = 32
|
||||
<div style='padding-left: 4em;'>
|
||||
2<sup>2</sup>=4, 2<sup>3</sup>=8, 2<sup>4</sup>=16, 2<sup>5</sup>=32 <br>
|
||||
3<sup>2</sup>=9, 3<sup>3</sup>=27, 3<sup>4</sup>=81, 3<sup>5</sup>=243 <br>
|
||||
4<sup>2</sup>=16, 4<sup>3</sup>=64, 4<sup>4</sup>=256, 4<sup>5</sup>=1024 <br>
|
||||
5<sup>2</sup>=25, 5<sup>3</sup>=125, 5<sup>4</sup>=625, 5<sup>5</sup>=3125 <br>
|
||||
</div>
|
||||
|
||||
32 = 9、33 = 27、34 = 81、35 = 243
|
||||
If they are then placed in numerical order, with any repeats removed, we get the following sequence of 15 distinct terms:
|
||||
|
||||
42 = 16、43 = 64、44 = 256、45 = 1024
|
||||
<div style='padding-left: 4em;'>
|
||||
4, 8, 9, 16, 25, 27, 32, 64, 81, 125, 243, 256, 625, 1024, 3125
|
||||
</div>
|
||||
|
||||
52 = 25、53 = 125、54 = 625、55 = 3125
|
||||
|
||||
如果然后按数字顺序放置它们,并删除所有重复项,则会得到以下15个不同术语的序列:
|
||||
|
||||
4,8,9,16,25,27,32,64,81,125,243,256,625,1024,3125
|
||||
|
||||
对于2≤a≤n和2≤b≤n,由ab生成的序列中有多少个不同的项?
|
||||
How many distinct terms are in the sequence generated by `ab` for 2 ≤ `a` ≤ `n` and 2 ≤ `b` ≤ `n`?
|
||||
|
||||
# --hints--
|
||||
|
||||
`distinctPowers(15)`应该返回177。
|
||||
`distinctPowers(15)` should return a number.
|
||||
|
||||
```js
|
||||
assert(typeof distinctPowers(15) === 'number');
|
||||
```
|
||||
|
||||
`distinctPowers(15)` should return 177.
|
||||
|
||||
```js
|
||||
assert.strictEqual(distinctPowers(15), 177);
|
||||
```
|
||||
|
||||
`distinctPowers(20)`应该返回324。
|
||||
`distinctPowers(20)` should return 324.
|
||||
|
||||
```js
|
||||
assert.strictEqual(distinctPowers(20), 324);
|
||||
```
|
||||
|
||||
`distinctPowers(25)`应该返回519。
|
||||
`distinctPowers(25)` should return 519.
|
||||
|
||||
```js
|
||||
assert.strictEqual(distinctPowers(25), 519);
|
||||
```
|
||||
|
||||
`distinctPowers(30)`应该返回755。
|
||||
`distinctPowers(30)` should return 755.
|
||||
|
||||
```js
|
||||
assert.strictEqual(distinctPowers(30), 755);
|
||||
|
Reference in New Issue
Block a user