question: Answer has to be drawn in this image.
Posted: Fri May 20, 2022 4:48 pm
question:
Answer has to be drawn in this image.
class LN: 1. (6 pts) Examine the mystery method and hand simulate the call mystery(x,y); using the linked list below. Lightly cross out ALL references that are replaced and Write in new references: don't erase any references. It will look a bit messy, but be as neat as you can. Show references to None as /. Do your work on scratch a paper first. def mystery (a,b): while b != None: def _init__(self, value, next=None) : self.value, self.next = value, next t = a.next next a.next next = b a = b def _init__(self, value, left=None, right=None) : self.value, self.left, self.right = value, left, right b = t class TN: X 1 2 3 4 4 / а t IMPORTANT: Submit your solution on Gradescope using Answers.pdf in the q6helper folder and also downloadable from Gradescope: point loss for using this document! b у 6 7 9
1. Draw hand-simulation in this box. Ensure it is readable. See Quiz for details. X 1 2 3 4 a t b Y 6 8 9
Answer has to be drawn in this image.
class LN: 1. (6 pts) Examine the mystery method and hand simulate the call mystery(x,y); using the linked list below. Lightly cross out ALL references that are replaced and Write in new references: don't erase any references. It will look a bit messy, but be as neat as you can. Show references to None as /. Do your work on scratch a paper first. def mystery (a,b): while b != None: def _init__(self, value, next=None) : self.value, self.next = value, next t = a.next next a.next next = b a = b def _init__(self, value, left=None, right=None) : self.value, self.left, self.right = value, left, right b = t class TN: X 1 2 3 4 4 / а t IMPORTANT: Submit your solution on Gradescope using Answers.pdf in the q6helper folder and also downloadable from Gradescope: point loss for using this document! b у 6 7 9
1. Draw hand-simulation in this box. Ensure it is readable. See Quiz for details. X 1 2 3 4 a t b Y 6 8 9