Part 2. (24pts) Consider the following lines from a MATLAB s…
Part 2. (24pts) Consider the following lines from a MATLAB script, starting in line 7… 7 m = 8 v0 = 9 10 TIM = m(1) .* v0(1)+m(2) .* v0(2) (total initial momentum in the system) 11 TIE = (1./2) .* (m) * ( (v0) * (v0) ) (total initial energy in the system) 12 13 Vf = TIM./m(1)+m(2) (final velocity, after m1 and m2 stick together) Like Part 1, you need to think about how to get these lines to compile properly, how to make them robust and efficient, how to make them relatively easy to read and understand, and how to make sure the output is appropriate for passing in, according to the guidelines you have been given so far in this course. Write the “fixed” code in the text boxes below, and explain everything you fixed and why. As before, there can be more than one “mistake” in each line of code. For full credit, make sure to explain why something is wrong.