56 lines
1.6 KiB
Markdown
56 lines
1.6 KiB
Markdown
|
---
|
||
|
id: 5900f39d1000cf542c50feb0
|
||
|
challengeType: 5
|
||
|
title: 'Problem 49: Prime permutations'
|
||
|
videoUrl: ''
|
||
|
localeTitle: 'المشكلة 49: التباديل رئيس الوزراء'
|
||
|
---
|
||
|
|
||
|
## Description
|
||
|
<section id="description"> التسلسل الحسابي ، 1487 ، 4817 ، 8147 ، حيث يزيد كل مصطلح من الشروط بحلول عام 3330 ، هو أمر غير عادي بطريقتين: (1) كل من المصطلحات الثلاثة رئيسة ، و (2) كل من الأرقام المكونة من 4 أرقام التباديل بين بعضها البعض. لا توجد تسلسلات حسابية تتكون من ثلاثة أو 1 أو 2 أو 3 أرقام ، تُظهر هذه الخاصية ، ولكن هناك تسلسل إضافي آخر مكون من 4 أرقام. ما هو الرقم المكون من 12 رقماً الذي تقوم بتكوينه من خلال تسلسل المصطلحات الثلاثة في هذا التسلسل؟ </section>
|
||
|
|
||
|
## Instructions
|
||
|
<section id="instructions">
|
||
|
</section>
|
||
|
|
||
|
## Tests
|
||
|
<section id='tests'>
|
||
|
|
||
|
```yml
|
||
|
tests:
|
||
|
- text: يجب أن ترجع primePermutations <code>primePermutations()</code> 296962999629.
|
||
|
testString: 'assert.strictEqual(primePermutations(), 296962999629, "<code>primePermutations()</code> should return 296962999629.");'
|
||
|
|
||
|
```
|
||
|
|
||
|
</section>
|
||
|
|
||
|
## Challenge Seed
|
||
|
<section id='challengeSeed'>
|
||
|
|
||
|
<div id='js-seed'>
|
||
|
|
||
|
```js
|
||
|
function primePermutations() {
|
||
|
// Good luck!
|
||
|
return true;
|
||
|
}
|
||
|
|
||
|
primePermutations();
|
||
|
|
||
|
```
|
||
|
|
||
|
</div>
|
||
|
|
||
|
|
||
|
|
||
|
</section>
|
||
|
|
||
|
## Solution
|
||
|
<section id='solution'>
|
||
|
|
||
|
```js
|
||
|
// solution required
|
||
|
```
|
||
|
</section>
|