CS208 Week 6 Homework

CS208 Week 6 Homework - appears first in alphabetical order...

Info icon This preview shows pages 1–4. Sign up to view the full content.

View Full Document Right Arrow Icon
1 2 E F A 2 1 2 1 1 3 1 G C 1 5 3 K 2 1 4 B D H F E A K G C H J B D A M N L H G F E D C B K CS208 - Week 6 Homework November 22, 2010 Discrete Math CS 208 Online 1. (Similar to Exercise 5.2 Question 19 on page 251) Starting from A, use Prim’s algorithm to find a minimal spanning tree  for the weighted graph. What is the total weight of the minimal spanning tree found? To obtain the full credit, you must show  the edges that form the minimal spanning tree. See the weekly Supplement for an example. Total Weight = 10 2. (Similar to Exercise 5.3 Question 3 on page 263) Given the following graph, starting vertex A, use the depth-first search  algorithm to obtain a depth-first search numbering of the vertices. If there is a choice of vertices, choose the vertex that 
Image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 2
Image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 4
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: appears first in alphabetical order. Vertices Depth-First Search Number Predecessor Unlabeled Adjacent Vertices A 1--C,F,G C 2 A G, H G 3 C H, J H 4 G J, F, D D 5 H F, B, K B 6 D K, E E 7 B F, K F 8 E None, back up to E K 9 E None, back up to E, B, D, H J 10 H None 3. ( Similar to Exercise 5.5 Questions 17, 23, and 29 on page 285 and page 286) Given the following binary tree, give the preorder, inorder, and postorder listing of vertices. The preorder is: A, K, E, G, L, B, H, N, F, D, C, M The inorder is: L, G, E, K, N, H, B, A, F, D, M, C The postorder is: L, G, E, N, H, B, K, M, C, D, F, A...
View Full Document

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern