COE 202, Term 052 Fundamentals of Computer Engineering HW# 1
COE 202, Term 052 Fundamentals of Computer Engineering HW# 1
COE 202, Term 052 Fundamentals of Computer Engineering HW# 1
Q.1.
Convert the following numbers from the given base to the bases indicated:
(i) Decimal 225.225 to binary, octal, and hexadecimal. (ii) Binary 11010111.110 to decimal, octal, and hexadecimal. (iii) Octal 623.77 to decimal, binary and hexadecimal. (iv) Hexadecimal 2AC5.D to decimal, octal and binary. Q.2. Perform the following arithmetic operations using the designated bases without converting to decimal. Verify your result by converting the numbers to decimal and then performing the operation in decimal:
(i) (10E)16 + (13F)16 (ii) (1E)16 * (10)16 (iii) (1101)2 * (1000)2 Q.3. Q.4. Q.5. Q.6. Obtain the 1`s and 2`s complement of the following binary numbers: 01100, 00001,00000 Find the 10`s complement of (935)11. Show how the decimal integer -120 would be represented in 2`s complement notation using 8 bits and 16 bits, respectively. Perform subtraction with the following binary numbers using 2`s complement and 1`s complement, assuming that numbers are represented in 6 bits. Check the answer by straight subtraction: 11010 - 1101
(i)
(ii) 11010 - 10000 (iii) 10010 - 10011 Q.7. (i) A microcontroller uses 8-bit registers. Give the following in both binary and decimal: The maximum unsigned number that can be stored.
(ii) The smallest (negative) number and the largest (positive) number that can be stored using the sign-magnitude notation. (iii) The smallest (negative) number and the largest (positive) number that can be stored using the 2`s complement notation.