Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Please help me with answering questions c, d, e, and problem 6. Thank you! When

ID: 3882872 • Letter: P

Question

Please help me with answering questions c, d, e, and problem 6. Thank you!

When data is coded in ASCII it is called "text."

c. The text "47" takes how many bytes to code (which will be stored)?

(I think the answer is 2 or 107? There are two characters, so one byte per character?

Or

4 = 0110 0100 = 32+16+4 =52

7 = 0011 0111 = 32+16+4+2+1 = 55

52 + 55 = 107)

d. The text "123" takes how many bytes to code (store)?

(For this I got either 3 or 150)

e. The text "1022" takes how many bytes to code (store)?

(For this I got either 4 or 198)

Problem 6: Would it take more bytes to code (store) the text "123" or the number "156" as a binary number? Explain your answer, stating how many bytes each would take and why. 10" as a binary number? Explain your answer, stating how many bytes each would take and why.

(This is the question I'm really stuck on. I think "123" would take more bytes because you have to code for each individual number separately ["1," "2," "3"]; whereas, "156" can be converted to and coded for using the binary equivalent of "1001 1100" Is this correct?)

Explanation / Answer

c. The text "47" takes how many bytes to code (which will be stored)?

Its just 47 , 47 can be represented in binary as 00101111 , so we can represent 47 itself in 8 bits so It will take 1 byte to be stored in memory

d. The text "123" takes how many bytes to code (store)?
123 will also be represnted in 8 bits , so we can represent 123 itself in 8 bits so It will take 1 byte to be stored in memory

e. The text "1022" takes how many bytes to code (store)?

1022 will require 10 bits i.e 1111111110 and it will comprise of two bytes will 6 leading zeros
0000001111111110 that means it will take 2 bytes to be stored in memory