2的14次方※
DD HW1 Answer
1.1
Base-10: 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 Octal: 20 21 22 23 24 25 26 27 30 31 32 33 34 35 36 37 40 Hex: 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 1D 1E 1F 20
Base-10: 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
Base-13: 8 9 A B C 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 20 21 22
1.4
14-bit binary: 11_1111_1111_1111
Decimal: 2的14次方 - 1 = (16,383)10
Hexadecimal: (3FFF)16
1.10
(a) 1.100102 = 0001.10012 = 1.916 = 1 + 9/16 = 1.56310
(b) 110.0102 = 0110.01002 = 6.416 = 6 + 4/16 = 6.2510
Reason: is the same as shifted to the left by two places.
1.13
(a) Convert 27.315 to binary:
27.315 = 11011.01012
(b) .101010102 = .1010_10102 = .AA16 = 10/16 + 10/256 = .664110
2/3 = .6666666667
(very close)
1.14
(a) 1000_0000 (b) 1101_1010 (c) 1000_0101
1s comp: 0111_1111 1s comp: 0010_0101 1s comp: 0111_1010 2s comp: 1000_0000 2s comp: 0010_0110 2s comp: 0111_1011
1.17
(a) 3409 -> 03409 -> 96590 (9s comp) -> 96591 (10s comp)
06428 - 03409 = 06428 + 96591 = 03019
(b) 6152 -> 06152 -> 93847 (9s comp) -> 93848 (10s comp)
2043 - 6152 = 02043 + 93848 = 95891(Negative)
Magnitude: 4109
Result: 2043 - 6152 = -4109
1.25
(a) BCD: 0101_0001_0011_0111
(b) Excess-3: 1000_0100_0110_1010
(c) 2421: 1011_0001_0011_1101
(d) 6311: 0111_0001_0100_1001
1.27
For a deck with 52 cards, we need 6 bits (32 < 52 < 64).Let the msb’s select the suit
(e.g., diamonds, hearts, clubs, spades are encoded respectively as 00, 01, 10, and 11. The
remaining four bits select the “number” of the card. Example: 0001 (ace) through 1011
(9), plus 101 through 1100 (jack, queen, king). This a jack of spades might be coded as
11_1010. (Note: only 52 out of 64 patterns are used.)
1.28
G (dot) (space) B o o l e 01000111_00101110_10100000_01000010_01101111_01101111_01101100_01100101
1.34
ASCII for decimal digits with odd parity:
(0): 10110000 (1): 00110001 (2): 00110010 (3): 10110011 (4): 00110100 (5): 10110101 (6): 10110110 (7): 00110111 (8): 00111000 (9): 10111001
1.35