Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix some typos in chapter 2 section 1.4 #11

Merged
merged 1 commit into from Feb 26, 2019

Conversation

davedx
Copy link
Contributor

@davedx davedx commented Feb 24, 2019

I found the explanation about irrational numbers a little confusing. What is the difference between Decimal(20.5) and Decimal(20.2)? Maybe a little bit more of an explanation would be good here.

@ericxiao251
Copy link
Owner

Sure thing! It can get a bit technical and out of the scope though. Essentially 20.5 is impossible to represent exactly in bits (that’s why its super long), but 20.2 is easily representable (not suprisingly as it’s essentially a binary number). I will show an example :).

@ericxiao251 ericxiao251 merged commit 01d9a92 into ericxiao251:master Feb 26, 2019
@ericxiao251
Copy link
Owner

Hey @davedx , I just updated the section to go into a bit more details about the difference in Decimal(20.5) and Decimal(20.2). I didn't go into too much as it would be a bit convoluted.

It basically boils down to how the numbers are represented in binary, I provided a link with an example of someone going through how you would calculate a similar value to Decimal(20.2), they used Decimal(263.3).

@davedx
Copy link
Contributor Author

davedx commented Feb 26, 2019

Looks good, thanks for clarifying it a bit more!

@davedx davedx deleted the fix-ch-2-s-1.4-typos branch February 26, 2019 11:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants