Introduction to Computing (CS101) Assignment # 01 Spring 2022

QUESTION NO. 1:-

SOLUTION:-

(a)

Convert the above 8-digit binary numbers into decimals. (6 marks)

Solution:

010010002 = (0×27) + (1×26) + (0×25) + (0×24) + (1×2 3) + (0×22) + (0×21) + (0×20)

=0+64+0+0+8+0+0+0

010010002 = 7210

 

011010012=

 (0×27) + (1×26) + (1×25) + (0×24) + (1×23) + (0×22) + (0×21) + (1×20)

= 0+64+32+0+8+0+0+1

011010012= 10510

 

 001011002=

 (0×27) + (0×26) + (1×25) + (0×24) + (1×23) + (1×22) + (0×21) + (0×20)

=0+0+32+0+8+4+0

 001011002= 4410

(b)

Convert the 8-digit binary into hexadecimal.                                            

Convert binary value to Hexa Decimal Value

Split the binary number from left to right each group 4 bits8421 0100                   1000

4                   8

010010002= 48

 

 

Convert binary value to Hexa Decimal Value

Split the binary number from left to right each group 4 bits8421 0110                 1001

6                 9

011010012= 69

 

Convert binary value to Hexa Decimal Value

Split the binary number from left to right each group 4 bits8421 0010                1100

2        C

001011002= 2C

(c)

Decode the 8-digit binary in textual form. (Hint: using the ASCII table). (3 marks)

 

Solution:

 

 

 

 

01001000

 

01101001

 

00101100

ACSII Codes

72

105

44

 

H

I

,

Textual Form is: Hi,

QUESTION NO. 2:-

SOLUTION:-

A

1

B

1

C

1

D

1

QUESTION NO. 3:-

SOLUTION:-

Extension

Example

Answer

.mp3

The logo of the Virtual University of Pakistan

The audio tracks of programming

talk-throughs.

.zip

The photo of the Rector on the faculty page.

A compressed folder of admission

documents.

.gif

The audio tracks of programming talk-

throughs.

The logo of the Virtual University of

Pakistan

.jpeg

A         compressed     folder of

admission

documents.

The photo of the Rector on the faculty page.

Post a Comment

Previous Post Next Post