9
Recitation 13 Professor Peck April 18, 2014

Recitation 13

  • Upload
    xena

  • View
    24

  • Download
    0

Embed Size (px)

DESCRIPTION

Recitation 13. Professor Peck April 18, 2014. Graph APTs. Complete the form: http://goo.gl/ vHUa4O the last character is an oh. Circuits. - PowerPoint PPT Presentation

Citation preview

Page 1: Recitation 13

Recitation 13

Professor Peck

April 18, 2014

Page 2: Recitation 13

Graph APTs• Complete the form: http://goo.gl/vHUa4O• the last character is an oh

Page 3: Recitation 13

Circuits• Discuss a solution to the Circuits APT in terms

of a high-level description of using DFS to keep track of the weight of the path being followed in the DFS. Since the graph is acyclic you don't need a visited set.

Page 4: Recitation 13

CircuitsQuestions 1-3

• Consider a modified DFS method as shown below:

Page 5: Recitation 13

Galaxy TripQuestions 4-7

Page 6: Recitation 13

Galaxy TripQuestions 8-10

• To find the size of a connected component (the number of machines that depend on each other starting from a specific machine), you can do a DFS or BFS.

Page 7: Recitation 13

Galaxy TripQuestions 11-12

• This code finds all possible values that can be created by adding together elements of sizes. Make sure you understand how this code works by summing elements of sizes together.  

Page 8: Recitation 13

Submit• Submit whatever you have finished BEFORE

you leave today!

• Please complete the following feedback form for your Recitation TAs• http://goo.gl/5HzEH0 (the last char is a zero)• Complete the form for EACH TA

Page 9: Recitation 13

• Happy Last Recitation!

• Have a great weekend!