0% found this document useful (0 votes)
9 views

Assignment 2 ICT

Uploaded by

iamhassanamer
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views

Assignment 2 ICT

Uploaded by

iamhassanamer
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Assignment Number 2 | Abdullah Sajid

UNIVERSITY OF WAH(UOW)
DEPARTMENT OF COMPUTER
SCIENCE

COURSE:
I C T GE.181

SUBMITTED TO:
Ma’am Saba Iqbal

SUBMITTED BY:
Abdullah Sajid
Class & Section

BS CS 1st B
De Department of Computer Science
UW Assignment#2

Course Code: GE-181 Discipline/Semester: BSCS-1st B


Course Title: : Application of ICT Submission Date/Deadline: Nov. 18th, 2024.
Total Marks: 20 Assigned Date: Nov. 12th , 2024

Q1: Convert the following given numbers into the given bases. (8)

i. (11011000111)2 = (?)8
Answer:
We are making groups of each three pairs from right to left:
011 = 0 x 22 + 1 x 21 + 1 x 20 = 0+2+1 = 3
011 = 0 x 22 + 1 x 21 + 1 x 20 = 0+2+1 = 3
000 = 0 x 22 + 0 x 21 + 0 x 20 = 0+0+0 = 0
111= 1 x 22 + 1 x 21 + 1 x 20 = 4+2+1 = 7
So, the conversion of
(11011000111)2 is equal to (3307)8
ii. (11110100011)2 = (?)16
Answer:
We are making groups of each four pairs from right to left:
0011 = 0 x 22 + 1 x 21 + 1 x 20 = 0+2+1 = 3
1010 = 1 x 23 + 0 x 22 + 1 x 21 + 0 x 20 = 8+0+2+0 = 10 = A
0111 = 0 x 23 +1 x 22 + 1 x 21 + 1 x 20 = 0+ 4+2+1 = 7
So, the conversion of
(11110100011)2 is equal to (3A7)16

1|Page
Q2: Convert the following given numbers into the given bases. (12)

i. (AF. D5)16 = (?)8


Answer:
we convert the hexadecimal number to binary.
A = 10 = (1010)2
F = 15 = (1111)2
D = 13 = (1101)2
5 = (0101)2
Now:
(AF. D5)16 = (10101111.11010110)2
(10101110.1101101)2 converting into Octal form:
We are making groups of each three pairs from right to left:
010 = 0 x 22 + 1 x 21 + 1 x 20 = 0+2+0 = 2
101 = 1 x 22 + 0 x 21 + 1 x 20 = 4+0+1 = 5
111 = 1 x 22 + 1 x 21 + 1 x 20 = 4+2+0 = 7
After point value:
110= 1 x 22 + 1 x 21 + 0 x 20 = 4+2+0 = 6
101= 1 x 22 + 0 x 21 + 1 x 20 = 4+1+0 = 5
010= 0 x 22 + 1 x 21 + 0 x 20 = 0+2+ 0 = 2
So, the conversion of
(10101111.11010110)2 is equal to (257.652)8
ii. (756.102)8 = (?)10
Answer:
We multiply each digit by its place value and add the products.
(756.102)8 = (7 × 82) + (5 × 81) + (6 × 80) + (1 × 8-1) + (0 × 8-2) + (2 × 8-3)
1 1 1
= (7 x 64) + (5 x 8) + (6 x 1) + (1 x 8 ) + (1 x 64 ) + (2 x 512 )

= 448 + 40 + 6 + 0.125 + 0.015625 + 0.0039629


= 494.180254

2|Page
So, the conversion of
(756.102)8 is equal to (494.130254)10
iii. (1011.011)2 = (?)10
Answer:
We multiply each binary digit by its place value and add the products.
(1011.011)2 = (1 × 23) + (0 × 22) + (1 × 21) + (1 × 20) + (0 × 2-1) + (1 × 2-2) + (1 × 2-3)
1 1 1
= 1 x 8 + 0 + 2 + 1 + (1 x 2 ) + (1 x 4 ) + (1 x )
8

= 8+ 0 + 2 +1 + 0.5 + 0.25 + 0.125


= (11.375)10
So, the conversion of
(1011.011)2 is equal to (11.375)10

iv. (332)4 = (?)6


Answer:

We multiply each digit by its place value and add the products.

(332)4 = (3 × 42) + (3 × 41) + (2 × 40)

= (3 × 16) + (3 × 4) + (2 × 1)

= 48 + 12 + 2

= (62)10

Divide the number repeatedly by 6 until the quotient becomes 0.

• When 62 is divided by 6, the quotient is 10 and the remainder is 2.


• When 10 is divided by 6, the quotient is 1 and the remainder is 4.
• When 1 is divided by 6, the quotient is 0 and the remainder is 1.

Write the remainders from bottom to top.

(62)10 = (142)6

3|Page

You might also like