Binary, I can't understand How I go from the first line to the second? http://screencast.com/t/xtMveJaOmatd
basically its a technique to convert a binary number to decimal
if you are given a binary number like 1 0 1 1 0 1 and you want you to find its decimal equavilant quickly then put the weight of each binary digit on its top like...
But why I cant apply this to it in order to convert it? http://screencast.com/t/HYKkQz9vXVF1
Add the numbers that have a 1 below them: -128+64+4+2=-58.
The think is why I can't use the method we were discussing before to solve this
Use whatever method which suits you ..some choose the shortcut way of not explicitly writing down each step rather they just add the weights on top of each number .
I try to apply this method http://screencast.com/t/HYKkQz9vXVF1 but it can't work. The thing is that I can't understand why
It has to do with the -128 weight in your example. Normally, 8 bits can cover the binary representation of the numbers 0..255, so 256 numbers. The number 198 then has a binary reperesentation of 11000110: It is: \(128+64+4+2=1 \cdot 2^7+1 \cdot2^6+0 \cdot2^5+0\cdot 2^4+0\cdot2^3+1\cdot2^2+1\cdot2^1+0\cdot2^0\). In this case, however, the weight of the first binary digit is set to be -128. Therefore the number that is described by "11000110" is 198-256=-58. This way of coding the numbers makes it possible to cover the range of -128..127 in binary.
How do you know that its 8 bits and not 16 for example ??
Silly me.... I got it.
YW!
Join our real-time social learning platform and learn together with your friends!