Parallel & Sequential Data Structures and Algorithms
CS 15210

Fall 2012
Homework 2
15210: Parallel and Sequential Data Structures and Algorithms (Fall12)
tag Version 1.0
due: mon, sep 17 @ 11:59pm
Disclaimer:
We will not grade noncompiling code.
1
Introduction
This assignment is meant to help you practice implementing, anal
Parallel & Sequential Data Structures and Algorithms
CS 15210

Fall 2012
Homework 1
15210: Parallel and Sequential Data Structures and Algorithms (Fall12)
tag Version 1.0
due: wed, sep 5 @ 11:59pm
1
Introduction
This assignment is meant to help you familiarize yourself with the handin mechanism for 15210 and to
get you thin
Parallel & Sequential Data Structures and Algorithms
CS 15210

Fall 2013
Set Signature
Definition:
A set S is a finite collection of unique elements of some type and the size of S. Size is denoted by S=
the number of elements in that set. The crucial difference between a set in the mathematical sense and a
set in this librar
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Homework 9
15210: Parallel and Sequential Data Structures and Algorithms (Spring12)
tag Version 1.5
due: wed, may 2 @ 11:59pm
Disclaimer:
We will not grade noncompiling code.
1
Introduction
This is the last homework this semester! You will do exercises
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 1 Parenthesis Matching
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2013)
January 16, 2013
Welcome to 210! This recitation is aimed at getting you started on Homework 1, which will be
released later today. We will be u
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 8 Midterm Feedback and Homework 6
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2013)
March 6, 2013
1
Topics
Homework 6 is out. You will be required to make some modications to Dijkstras Algorithm and also
use DFS to n
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 14 Hashing
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2013)
April 24, 2013
Todays Agenda:
 Parallel Hashing
 Removing Duplicates
1
Hashing Review
We have a large space Ske ys of keys (this might be innite as in the
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 5 Graphs and StSeqs
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2013)
February 13, 2013
1
Announcements
How did Assignment 3 go?
Assignment 4 has been released.
Questions?
2
Graph Representations
Suppose youre give
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 4 Scan, Reduction, MapCollectReduce
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2013)
February 6, 2013
1
Announcements
How did HW 2 go?
HW 3 is outget an early start!
Questions about homework or lecture?
2
Scan Imp
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 3 Scan
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2013)
January 30, 2013
1
Announcements
HW 2 is due next Monday. Hopefully you have all started by now; if not, now would be a good
time.
Questions from lecture or h
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 6 BFS, DFS and Staging
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2013)
February 20, 2013
1
Announcements
How did Homework 4 go?
Homework 5 has been released.
Questions?
2
DFS vs. BFS
Recall the DFS algorithm:
fun
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 2 Recurrences
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2013)
January 23, 2012
1
Announcements
HW1 is due on Monday January 28. Hopefully you have all started by now; if not, now would
be a good time.
If you are n
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 13 Dynamic Programming
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2013)
April 17, 2013
1
Dynamic Programming
Dynamic programming is a technique to avoid needless recomputation of answers to subproblems.
Q: When is it
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Parallel and Sequential Data Structures and Algorithms Lecture 15
15210 (Spring 2012)
Lecture 15 Quicksort and Treaps
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Margaret ReidMiller 6 March 2012
Today:
 Quic
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
15210 (Spring 2012)
Parallel and Sequential Data Structures and Algorithms Lecture 19
Lecture 19 Graph Contraction III: Parallel MST and MIS
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Kanat Tangwongsan March
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Parallel and Sequential Data Structures and Algorithms Lecture 17
15210 (Spring 2012)
Lecture 17 Graph Contraction I: Tree Contraction
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Kanat Tangwongsan March 20, 20
Parallel & Sequential Data Structures and Algorithms
CS 15210

Fall 2013
The BST Signature
BST is a binary search tree.
used as a way to efficiently conduct binary search
steps to using a BST
1. Compare the current node to what we are looking for. Stop if equal.
2. If what we are looking for is smaller, proceed to the left s
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Parallel and Sequential Data Structures and Algorithms Lecture 9
15210 (Spring 2012)
Lecture 9 DepthFirst Search, TopSort, and SingleThreaded Arrays
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Kanat Tangwong
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Parallel and Sequential Data Structures and Algorithms Lecture 4
15210 (Spring 2012)
Lecture 4 ADTs, Reduce, and Scan
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Margaret ReidMiller 26 January 2012
1
Abstract
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Parallel and Sequential Data Structures and Algorithms Lecture 14
15210 (Spring 2012)
Lecture 14 Search Trees I: BSTs Split and Join
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Kanat Tangwongsan March 1, 2012
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Parallel and Sequential Data Structures and Algorithms Lecture 11
15210 (Spring 2012)
Lecture 11 Shortest Weighted Paths II
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Margaret ReidMiller 21 February 2012
 C
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Parallel and Sequential Data Structures and Algorithms Lecture 16
15210 (Spring 2012)
Lecture 16 Treaps; Augmented BSTs
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Margaret ReidMiller 8 March 2012
Today:
 Mo
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Parallel and Sequential Data Structures and Algorithms Lecture 23
15210 (Spring 2012)
Lecture 23 Dynamic Programming I
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Margaret ReidMiller 10 April 2012
Today:
 In
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Parallel and Sequential Data Structures and Algorithms Lecture 25
15210 (Spring 2012)
Lecture 25 Sufx Arrays
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Kanat Tangwongsan April 17, 2012
Material in this lectur
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Parallel and Sequential Data Structures and Algorithms Lecture 26
15210 (Spring 2012)
Lecture 26 Hash Tables
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Margaret ReidMiller 24 April 2012
Today:
 Hashing
 Ha
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Parallel and Sequential Data Structures and Algorithms Lecture 18
15210 (Spring 2012)
Lecture 18 Graph Contraction II: Connectivity and MSTs
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2012)
Lectured by Kanat Tangwongsan March
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 15 Leftist Heaps and Practice Problems
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2013)
May 1, 2013
Todays Agenda:
 Leftist Heaps
 WeightBiased Leftist Heaps
 Practice Problems
1
Heaps
Recall from lecture that a
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Homework 7
15210: Parallel and Sequential Data Structures and Algorithms (Spring12)
tag Version 1.0
due: tue, apr 3 @ 11:59pm
Disclaimer:
We will not grade noncompiling code.
1
Introduction
In this homework, you will implement the parallel Minimum Spann
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 14 Dynamic Programming!
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2014)
April 15th , 2014
1
Announce Dynamically
RangeLab is due on Wednesday! DPLab is coming out on Wednesday!
Questions about homework or lecture?
Parallel & Sequential Data Structures and Algorithms
CS 15210

Summer 2013
Recitation 15 Priority Queues, Hashing, and Leftist Heaps
Parallel and Sequential Data Structures and Algorithms, 15210 (Spring 2014)
April 22nd , 2014
1
Announcements
DPLab is due on Wednesday.
CilkLab is coming out on Wednesday! You will get some exp