![]() |
binary counting
This is a question from my digital logic book
Quote:
|
Re: binary counting
Is it in the context of programming? As far as I know, no 7 bit datatype exists. You can use bitfields to separate bytes into odd amounts of bits. But other then that, to store something distinguished by 7 bits, you would need an 8 bit datatype. So you are correct, but that may have been the reasoning behind the answer.
Edit : Unless it's something like each object is distinguished by two values. IE. The first object takes values 0-1. The second object takes values 2-3. So on and so forth. Then 108*2 = 216. Which takes 8 bits of memory. |
Re: binary counting
there is no contex to programming. the chapter the question is from is on the concepts of binary for computing, logic gates and true tables. It was not on the full topic of computer numbering systems.
I think your edit statement is correct. The question is vauge to me. I thought the answer to be Object A can be labeled as 1, Object B can be labeled as 2 and so on, thus 108 is the total of unique objects and convert it to binary. I don't see how the question implies that Objects have the state of being on or off, a binary nature, leading to the solution of 108*2 to binary which uses 8 bits. :icon_confused: |
Re: binary counting
Could you post the question in its entirity? Maybe it has a vague way of implying that each object requires 2 values per entry.
|
Re: binary counting
That is the entire question, verbatim!
|
Re: binary counting
I guess by "distinguish", the question means "distinguish whether 108 objects are there or not". If you had 8 bits, you could set object #77 to on. And object #31 to off. Etc etc. That's how you distinguish them. Otherwise with 7 bits you could only list the number of objects that are set to on. You could only say with
100 0000, that "all objects up to #64 are on, and everything past is off".But this is just my guess based on the answer they gave... |
Re: binary counting
Quote:
|
Re: binary counting
Quote:
Disregard my last post, look at my second post's edit then... I'm not exactly sure why the question would imply that each object requires two values though. My theory has no supporting evidence. So I would have no clue bud. XD |
Re: binary counting
Sign bit?
|
Re: binary counting
Quote:
|
| All times are GMT -5. The time now is 8:41 AM. |
Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC