freeCodeCamp/curriculum/challenges/arabic/02-javascript-algorithms-an.../basic-javascript/divide-one-number-by-anothe...

60 lines
1.3 KiB
Markdown

---
id: cf1111c1c11feddfaeb6bdef
title: Divide One Number by Another with JavaScript
challengeType: 1
videoUrl: ''
localeTitle: قسمة رقم واحد على آخر باستخدام JavaScript
---
## Description
<section id="description"> يمكننا أيضًا تقسيم رقم واحد بآخر. تستخدم جافا سكريبت الرمز <code>/</code> للقسمة. <p style=";text-align:right;direction:rtl"> <strong>مثال</strong> </p><blockquote style=";text-align:right;direction:rtl"> myVar = 16/2؛ // تعيين 8 </blockquote></section>
## Instructions
<section id="instructions"> تغيير <code>0</code> بحيث يكون <code>quotient</code> تساوي <code>2</code> . </section>
## Tests
<section id='tests'>
```yml
tests:
- text: اجعل <code>quotient</code> المتغير تساوي 2.
testString: 'assert(quotient === 2, "Make the variable <code>quotient</code> equal to 2.");'
- text: استخدم <code>/</code> المشغل
testString: 'assert(/\d+\s*\/\s*\d+/.test(code), "Use the <code>/</code> operator");'
```
</section>
## Challenge Seed
<section id='challengeSeed'>
<div id='js-seed'>
```js
var quotient = 66 / 0;
```
</div>
### After Test
<div id='js-teardown'>
```js
console.info('after the test');
```
</div>
</section>
## Solution
<section id='solution'>
```js
// solution required
```
</section>