← Winnitude! Search  ·  Reader Mode (1878 ms)
Links: Stay in Reader Retro Site Converter Retro Mode: OFF Original Page ↗
GITHUB · 90 LINKS

BigInt by amirhshahbazi · Pull Request #120 · javascript-tutorial/fa.javascript.info

Repository navigation

BigInt - #120


Merged
mahdyar merged 3 commits into javascript-tutorial:master from amirhshahbazi:BigInt May 6, 2021
Merged

BigInt #120 mahdyar merged 3 commits into javascript-tutorial:master from amirhshahbazi:BigInt

Conversation

amirhshahbazi commented May 4, 2021



Copy link Copy Markdown
Contributor

Translated the BigInt page.

correct true and false 0bf0fe2 javascript-translate-bot added the review needed label May 4, 2021 javascript-translate-bot requested a review from a team May 4, 2021 17:19

javascript-translate-bot commented May 4, 2021



Copy link Copy Markdown

Error: the article already has PR number in the Progress Issue #1 , it's 117 ⁉️

mahdyar requested changes May 4, 2021
View reviewed changes

mahdyar left a comment · edited Loading



Copy link Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more .

You don't need to make a new pull request for any changes you make. you can add more commits by pushing to the BigInt branch on your fork.
In addition to that, please read the Translation Tips :

Please keep line breaks and paragraphs "as is": don't add new lines and don't remove existing ones. Makes it easy to merge future changes from the English version into the translation.

You've removed the newline on line 8, please add it back.

javascript-translate-bot added changes requested and removed review needed labels May 4, 2021

javascript-translate-bot commented May 4, 2021



Copy link Copy Markdown

Please make the requested changes. After it, add a comment "/done".
Then I'll ask for a new review 👻

add missed new line 7254d00

amirhshahbazi commented May 4, 2021



Copy link Copy Markdown
Contributor

Author

Thanks for the review, @mahdyar
/done

javascript-translate-bot added review needed and removed changes requested labels May 4, 2021 javascript-translate-bot requested a review from a team May 4, 2021 19:18 mahdyar requested changes May 4, 2021
View reviewed changes
Comment thread 1-js/99-js-misc/05-bigint/article.md
Outdated
```

## Math operators
## عملیات ریاضی
Comment thread 1-js/99-js-misc/05-bigint/article.md
Outdated
```

Please note: the division ` 5/2 ` returns the result rounded towards zero, without the decimal part. All operations on bigints return bigints .
در نظر داشته باشید: عملیات تقسیم 5/2 نتیجه را بدون قسمت اعشار و رند شده به سمت صفر، باز می گرداند. همه ی عملیات بر روی bigint ها، مقداری را از نوع bigint باز می گردانند .
Comment thread 1-js/99-js-misc/05-bigint/article.md
Outdated

```js run
alert(1n + 2); // Error : Cannot mix BigInt and other types
alert(1n + 2); // خطا : Cannot mix BigInt and other types
Comment thread 1-js/99-js-misc/05-bigint/article.md
Outdated
```

We should explicitly convert them if needed: using either `BigInt()` or `Number()` , like this :
می بایست آن ها ابتدا به صورت زیر، توسط `BigInt()` یا `Number()` تبدیل کرد :
Comment thread 1-js/99-js-misc/05-bigint/article.md
Outdated
````

## Comparisons
## عملگرهای مقایسه
Comment thread 1-js/99-js-misc/05-bigint/article.md
Outdated
alert( +bigint ); // خطا
```
So we should use `Number()` to convert a bigint to a number .
باید ابتدا از `Number()` برای تبدیل یک bigint به نوع عددی استفاده کرد .
Comment thread 1-js/99-js-misc/05-bigint/article.md
Outdated
alert( 1n || 2 ); // 1 (1n برابر با true است )

alert( 0n || 2 ); // 2 (0n is considered falsy )
alert( 0n || 2 ); // 2 (0n برابر با false است )
javascript-translate-bot removed the review needed label May 4, 2021

javascript-translate-bot commented May 4, 2021



Copy link Copy Markdown

Please make the requested changes. After it, add a comment "/done".
Then I'll ask for a new review 👻

javascript-translate-bot added the changes requested label May 4, 2021 replace incorrect translations 7599354

amirhshahbazi commented May 5, 2021



Copy link Copy Markdown
Contributor

Author

Thanks,
/done

javascript-translate-bot added review needed and removed changes requested labels May 5, 2021 javascript-translate-bot requested a review from a team May 5, 2021 21:09 mahdyar approved these changes May 6, 2021
View reviewed changes

mahdyar left a comment



Copy link Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more .

Thank you, @amirhshahbazi !

javascript-translate-bot added needs +1 and removed review needed labels May 6, 2021 mahdyar merged commit 1f21ed1 into javascript-tutorial : master May 6, 2021 mahdyar mentioned this pull request May 6, 2021 Persian (Farsi) Translation Progress #1 Open javascript-tutorial deleted a comment from javascript-translate-bot May 6, 2021 Sign up for free to join this conversation on GitHub . Already have an account? Sign in to comment

Labels

needs +1

3 participants