Computer Science 9608 · 13

Data representation

22 questions. Open a question to solve it and check the official answer.

Reset
2015 October-November · Paper 31 · Q1(a)(i)

Floating-point representation and manipulation · 3 marks · official answer ready

(i) A real number is stored as the following two bytes: Mantissa Exponent Calculate the denary value of this number. Show your working. ...........................................…

2015 October-November · Paper 31 · Q1(a)(ii)

Floating-point representation and manipulation · 2 marks · official answer ready

(ii) Explain why the floating-point number in part (a)(i) is not normalised. ......................................................................................................…

2015 October-November · Paper 31 · Q1(a)(iii)

Floating-point representation and manipulation · 2 marks

(iii) Normalise the floating-point number in part (a)(i). Mantissa Exponent [2] 3

2015 October-November · Paper 31 · Q1(b)(i)

Floating-point representation and manipulation · 2 marks · official answer ready

(i) Write the largest positive number that can be written as a normalised floating-point number in this format. Mantissa Exponent [2]

2015 October-November · Paper 31 · Q1(b)(ii)

Floating-point representation and manipulation · 2 marks

(ii) Write the smallest positive number that can be written as a normalised floating-point number in this format. Mantissa Exponent [2]

2015 October-November · Paper 31 · Q1(b)(iii)

Floating-point representation and manipulation · 2 marks · official answer ready

(iii) If a positive number is added to the number in part (b)(i) explain what will happen. ........................................................................................…

2015 October-November · Paper 31 · Q1(c)

Floating-point representation and manipulation · 3 marks · official answer ready

(c) A student writes a program to output numbers using the following code: X 0.0 FOR i 0 TO 1000 X X + 0.1 OUTPUT X ENDFOR The student is surprised to see that the program outputs…

2015 October-November · Paper 32 · Q1(a)(i)

Floating-point representation and manipulation · 3 marks

(i) A real number is stored as the following 12-bit binary pattern: Calculate the denary value of this number. Show your working. .................................................…

2015 October-November · Paper 32 · Q1(a)(ii)

Floating-point representation and manipulation · 3 marks · official answer ready

(ii) Give the normalised binary pattern for +3.5. Show your working. ..............................................................................................................…

2015 October-November · Paper 32 · Q1(a)(iii)

Floating-point representation and manipulation · 3 marks · official answer ready

(iii) Give the normalised binary pattern for –3.5. Show your working. .............................................................................................................…

2015 October-November · Paper 32 · Q1(b)(i)

Floating-point representation and manipulation · 1 mark · official answer ready

(i) If the system were to use the extra 4 bits for the mantissa, state what the effect would be on the numbers that can be represented. ...........................................…

2015 October-November · Paper 32 · Q1(b)(ii)

Floating-point representation and manipulation · 1 mark · official answer ready

(ii) If the system were to use the extra 4 bits for the exponent instead, state what the effect would be on the numbers that can be represented. ..................................…

2015 October-November · Paper 32 · Q1(c)

Floating-point representation and manipulation · 3 marks · official answer ready

(c) A student enters the following expression into an interpreter: OUTPUT (0.1 + 0.2) The student is surprised to see the following output: Explain why this output has occurred. .…

2015 October-November · Paper 33 · Q1(a)(i)

Floating-point representation and manipulation · 3 marks · official answer ready

(i) A real number is stored as the following two bytes: Mantissa Exponent Calculate the denary value of this number. Show your working. ...........................................…

2015 October-November · Paper 33 · Q1(a)(ii)

Floating-point representation and manipulation · 2 marks · official answer ready

(ii) Explain why the floating-point number in part (a)(i) is not normalised. ......................................................................................................…

2015 October-November · Paper 33 · Q1(a)(iii)

Floating-point representation and manipulation · 2 marks

(iii) Normalise the floating-point number in part (a)(i). Mantissa Exponent [2] 3

2015 October-November · Paper 33 · Q1(b)(i)

Floating-point representation and manipulation · 2 marks · official answer ready

(i) Write the largest positive number that can be written as a normalised floating-point number in this format. Mantissa Exponent [2]

2015 October-November · Paper 33 · Q1(b)(ii)

Floating-point representation and manipulation · 2 marks

(ii) Write the smallest positive number that can be written as a normalised floating-point number in this format. Mantissa Exponent [2]

2015 October-November · Paper 33 · Q1(b)(iii)

Floating-point representation and manipulation · 2 marks · official answer ready

(iii) If a positive number is added to the number in part (b)(i) explain what will happen. ........................................................................................…

2015 October-November · Paper 33 · Q1(c)

Floating-point representation and manipulation · 3 marks · official answer ready

(c) A student writes a program to output numbers using the following code: X 0.0 FOR i 0 TO 1000 X X + 0.1 OUTPUT X ENDFOR The student is surprised to see that the program outputs…