NW | 2026-mar-sdc | TzeMing Ho | Sprint 1 | number-systems-exercise#357
Open
TzeMingHo wants to merge 3 commits intoCodeYourFuture:mainfrom
Open
NW | 2026-mar-sdc | TzeMing Ho | Sprint 1 | number-systems-exercise#357TzeMingHo wants to merge 3 commits intoCodeYourFuture:mainfrom
TzeMingHo wants to merge 3 commits intoCodeYourFuture:mainfrom
Conversation
This comment has been minimized.
This comment has been minimized.
4 similar comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
2 similar comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
number-systems/README.md
Outdated
|
|
||
| Which is larger: 00100 or 01011? | ||
| Answer: | ||
| Answer: 01011 is larger because it has more places |
There was a problem hiding this comment.
it's more important what the leading digit is
Author
There was a problem hiding this comment.
Yeah. I should have said the leading 1 is taking more places, and they are both 5 bits.
number-systems/README.md
Outdated
|
|
||
| Convert the decimal number 14 to binary. | ||
| Answer: | ||
| Answer: 1000 + 0100 + 0010 = 1110 = 8 + 4 + 2 = 14 |
There was a problem hiding this comment.
which method have you used here exactly?
Author
There was a problem hiding this comment.
I was trying to subtract the power of 2 from 14 to get the binary numbers.
14 - 2^3 = 6
6 - 2^2 = 2
2 = 2^1
number-systems/README.md
Outdated
|
|
||
| What's the largest number you can store with 4 bits, if you want to be able to represent the number 0? | ||
| Answer: | ||
| Answer: 1111 |
number-systems/README.md
Outdated
|
|
||
| How many bits would you need in order to store the numbers between 0 and 255 inclusive? | ||
| Answer: | ||
| Answer: 2^8 = 256. So, we need 7 bits. b0000000 = 0, and b1111111 = 255 |
Author
There was a problem hiding this comment.
Oh. I was 1 bit off. It should take 8 bits to store from 0 to 255.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Learners, PR Template
Self checklist
Changelist
I have attempted to answer the questions.