Name GT#________
ESC2030h Fall โ01 - Quiz 1 p. 1 of 5
ECE 2030h, Intro. To Computer Eng., QUIZ 2 - Answers
Quiz No. 2: Oct. 18, 2001
Prof. John A. Copeland
School of Electrical and Computer Engineering
RULES.
iThis quiz is closed book.
ii. Non-programable calculators may be used.
iii Answer all questions and show all work to receive full credit.
iv All questions have the same weight. (20 Points). All sub-questions within a
question are weighted equally.
vPlease do not ask the proctors any questions during the exam about exam
questions. Part of the test is understanding the question as written, without supplemental
information. If you feel additional data is needed to solve the problem, make (and state) an
assumption and then work the problem.
Question 1 โ Binary Number to Decimal Conversion.
A. Show how to convert a decimal integer (58) to a binary integer by repeated division by 2.
58 โ even, least significant bit (lsb) is 0. 58/2 = 29 r = 0
58/2 = 29 โ odd, subtract 1 and next lsb is 1. 29/2 = 14 r = 1
28/2 = 14 โ even, next lsb is 0. 14/2 = 7 r = 0
14/2 = 7 โ odd, subtract 1 and next lsb is 1. 7/2 = 3 r = 1
6/2 = 3 โ odd, subtract 1 and next lsb is 1. 3/2 = 1 r = 1
2/2 = 1 โ odd, subtract 1 and next lsb is 1. 1/2 = 0 r = 1
Binary number is 111010
B. Show how to convert a decimal fraction (0.626) to binary (4-bit accuracy) by repeated multiplication by
2.
2 * 0.626 = 1.252 โ greater than 1.0, subtract 1 and most significant bit (msb) is 1 -> 0.1
2*0.252 = 0.504 โ less than 1.0, next msb is 0, -> 0.10
2*0.504 = 1.008 โ greater than 1.0, subtract 1 and next msb is 1 -> 0.101
2*0.008 = 0.016 โ less than 1.0, next msb is 0, -> 0.1010
Binary decimal fraction is 0.1010