2 - Number System
2 - Number System
Fundamentals
Tenth Edition
Floyd
Number Systems
and Codes
• Objectives
– Number systems (Decimal, Binary,
Hexadecimal)
– Conversions
– Arithmetic
– BCD
• Reading assignments
– Chapter2 p46 - p97
…25 24 23 22 21 20.
• For fractional binary numbers, the column weights are
negative powers of two that decrease from left to right:
2 49 Quotient
2 24 ……..…1 LSB
Least Significant Bit
2 12 ……..…0
2 6 ……..…0
2 3 ……..…0
2 1 ……..…1 MSB
0 ……..…1 Most Significant Bit
0 0 1 1 0 1 0 1
0 0 1 1 0 1 0 1
Input bits
Carry
Adder
in (add 1)
Output bits (sum)
0 0 1 1 0 1 1 0
Binary sequence
Gray code sequence
Floyd, Digital ©
Fundamentals, 10th ed
2008 Pearson Education
2. The 2’s complement of 1000 is
a. 0111
b. 1000
c. 1001
d. 1010
Floyd, Digital ©
Fundamentals, 10th ed
2008 Pearson Education
3. The fractional binary number 0.11 has a decimal value
of
a. ¼
b. ½
c. ¾
d. none of the above
Floyd, Digital ©
Fundamentals, 10th ed
2008 Pearson Education
4. The hexadecimal number 2C has a decimal equivalent
value of
a. 14
b. 44
c. 64
d. none of the above
Floyd, Digital ©
Fundamentals, 10th ed
2008 Pearson Education
5. Assume that a floating point number is represented in
binary. If the sign bit is 1, the
a. number is negative
b. number is positive
c. exponent is negative
d. exponent is positive
Floyd, Digital ©
Fundamentals, 10th ed
2008 Pearson Education
6. When two positive signed numbers are added, the result
may be larger that the size of the original numbers,
creating overflow. This condition is indicated by
a. a change in the sign bit
b. a carry out of the sign position
c. a zero result
d. smoke
Floyd, Digital ©
Fundamentals, 10th ed
2008 Pearson Education
7. The number 1010 in BCD is
a. equal to decimal eight
b. equal to decimal ten
c. equal to decimal twelve
d. invalid
Floyd, Digital ©
Fundamentals, 10th ed
2008 Pearson Education
8. An example of an unweighted code is
a. binary
b. decimal
c. BCD
d. Gray code
Floyd, Digital ©
Fundamentals, 10th ed
2008 Pearson Education
9. An example of an alphanumeric code is
a. hexadecimal
b. ASCII
c. BCD
d. CRC
Floyd, Digital ©
Fundamentals, 10th ed
2008 Pearson Education
10. An example of an error detection method for
transmitted data is the
a. parity check
b. CRC
c. both of the above
d. none of the above
Floyd, Digital ©
Fundamentals, 10th ed
2008 Pearson Education
Answers:
1. c 6. a
2. b 7. d
3. c 8. d
4. b 9. b
5. a 10. c