PLEASE READ AS PERVIOUS ANSWERS WERE INCCORECT Parts a and b of this question involve creating drawings or descriptions.
Posted: Fri Jul 08, 2022 6:36 am
PLEASE READ AS PERVIOUS ANSWERS WERE INCCORECT
Parts a and b of this question involve creating drawings ordescriptions.
You can make your drawings whichever way is easiest or fastestfor you. For instance, you could simply make your drawings usingpencil and paper then scan or photograph them.
Alternatively, you can answer by providing descriptions of thedrawings. In that case, keep close to the formulations used in thelong figure descriptions of the examples given in Section 4.5 ofBlock 2 Part 4.
a.Consider the following lines entered on the Python shell
>>> pass_TMA02 = True
>>> id(pass_TMA02)
140722250372944
>>> type(pass_TMA02)
<class 'bool'>
>>> pass_TMA02
True
Draw (or describe) the object and its labelthat the Python interpreter creates in response to theassignment pass_TMA02 = True in the interactiveshell above. Your drawing or description should include a Booleanobject with a similar level of detail as Figure 4.14 in Section4.5.1 (Page 216) and a label.
Include your drawing or text description of theobject and label in the solution document.
(2 marks)
b.Consider the following two assignments
o my_appointments = ['Morning', 'Afternoon', 'Evening']
o my_appointments[1] = 'Attended'
Draw (or describe) the objects and labels that the Pythoninterpreter creates in response to the first assignment.
Then draw (or describe) the objects and labels that results fromcarrying out the second assignment immediately after the firstassignment.
Include your drawings or text descriptions in the solutiondocument.
Parts a and b of this question involve creating drawings ordescriptions.
You can make your drawings whichever way is easiest or fastestfor you. For instance, you could simply make your drawings usingpencil and paper then scan or photograph them.
Alternatively, you can answer by providing descriptions of thedrawings. In that case, keep close to the formulations used in thelong figure descriptions of the examples given in Section 4.5 ofBlock 2 Part 4.
a.Consider the following lines entered on the Python shell
>>> pass_TMA02 = True
>>> id(pass_TMA02)
140722250372944
>>> type(pass_TMA02)
<class 'bool'>
>>> pass_TMA02
True
Draw (or describe) the object and its labelthat the Python interpreter creates in response to theassignment pass_TMA02 = True in the interactiveshell above. Your drawing or description should include a Booleanobject with a similar level of detail as Figure 4.14 in Section4.5.1 (Page 216) and a label.
Include your drawing or text description of theobject and label in the solution document.
(2 marks)
b.Consider the following two assignments
o my_appointments = ['Morning', 'Afternoon', 'Evening']
o my_appointments[1] = 'Attended'
Draw (or describe) the objects and labels that the Pythoninterpreter creates in response to the first assignment.
Then draw (or describe) the objects and labels that results fromcarrying out the second assignment immediately after the firstassignment.
Include your drawings or text descriptions in the solutiondocument.