CSE 101 Fall 2016
Homework 1
Due: Wednesday, January 18, 2017 at 11:59pm
Instructions
Homework should be done in groups of one to four people. You are free to change group
members at any time throughout the quarter. Problems should be solved together, not
Name: _
PID: _
Homework 5
Instructions:
1. Print out this PDF
double-sided
. (You will turn in your solutions
written on your printed copy)
2. There are 5 questions.
3. MAKE SURE YOUR ANSWER IS WRITTEN DOWN IN THE
PROVIDED SPACE FOR THAT QUESTION. We wil
Name: _ PID: _
Homework 3
Instructions:
1. Print out this PDF double-sided. (You will turn in your solutions
written on your printed copy)
2. There are 5 questions.
3. Make sure your answer i
CSE 101
Algorithm Design and Analysis
Miles Jones
mej016@eng.ucsd.edu
Office 4208 CSE Building
Lecture 11: MST
GREEDY-STAYS-AHEAD
In this proof technique, lets revisit the original event scheduling
problem.
We want to show that at every step the greedy
CSE 101
Algorithm Design and Analysis
Miles Jones
mej016@eng.ucsd.edu
Office 4208 CSE Building
Lecture 9: Greedy
GENERAL PROBLEM SOLVING
In general, when you try to solve a problem, you are trying to find
a solution from among a large space of possibilit
CSE 101
Algorithm Design and Analysis
Miles Jones
mej016@eng.ucsd.edu
Office 4208 CSE Building
Lecture 2: Asymptotics
A BETTER APPROACH?
function fib2(n)
if n = 0 then return 0
create array f[0n]
f[0] := 0
f[1] := 1
for i = 2 n:
f[i]:=f[i 1] + f[i 2]
retu
CSE 101
Algorithm Design and Analysis
Miles Jones
mej016@eng.ucsd.edu
Office 4208 CSE Building
Lecture 13: Prims
EXAMPLE
PRIMS ALGORITHM
Prims algorithm is another way to produce an MST from an
undirected connected graph with positive edge weights.
Prim
CSE 101 Winter 2017
Homework 4
Due: Thursday, February 9, 2017 at 11:59pm
Instructions
Homework should be done in groups of one to four people. You are free to change group
members at any time throughout the quarter. Problems should be solved together, no
CSE 101 Winter 2017
Homework 2
Due: Wednesday, January 25, 2017 at 11:59pm
Instructions
Homework should be done in groups of one to four people. You are free to change group
members at any time throughout the quarter. Problems should be solved together, n
CSE 101 Fall 2016
Homework 3
Due: Wednesday, February 1, 2017 at 11:59pm
Instructions
Homework should be done in groups of one to four people. You are free to change group
members at any time throughout the quarter. Problems should be solved together, not
Midterm 1 review
CSE 101, Winter 2017
Professor Miles Jones
1. When there is a choice, pick the vertex that is next in alphabetical order
a. Perform BFS on the given graph
b. Perform DFS on the given graph and mark each edge as tree/forward/back/edge.
2.
Practice problems for Midterm/Quiz/Exam 2
True/False. Give a SHORT justification/ counterexample for your answer
1. Let G be a weighted graph, with edge weights that are positive and distinct. Let T be a minimum spanning tree for this graph. Now suppose
w
Name: _
PID: _
Homework 6
Instructions:
1. Print out this PDF
double-sided
. (You will turn in your solutions
written on your printed copy)
2. There are 5 questions.
3. Make sure your answer is written down in the provided space
for that question. We wil