CS 331: Algorithms and Complexity (Fall 2015)
Unique numbers: 50690, 50695, 50700, 50705, 50710, 50715
Assignment 3
Due on Thursday, September 24th , by 11.59pm
Problem 1
(10 points)The head nurse in a hospital is responsible for n nurses, each of whom is

THE PRINCE
by Nicolo Machiavelli
Translated by W. K. Marriott
Nicolo Machiavelli, born at Florence on 3rd May 1469. From 1494 to 1512
held an official post at Florence which included diplomatic missions to
various European courts. Imprisoned in Florence,

BEOWULF
AN ANGLO-SAXON EPIC POEM
TRANSLATED
FROM THE HEYNE-SOCIN TEXT
BY
JNO: LESSLIE HALL, Ph. D. (J.H.U.)
Professor of English and History in The College of William and Mary
D.C. HEATH & CO., PUBLISHERS
BOSTON NEW YORK CHICAGO
Entered according to Act

Frankenstein,
or the Modern Prometheus
by
Mary Wollstonecraft (Godwin) Shelley
CONTENTS
Letter 1 Letter 2 Letter 3 Letter 4
Chapter 1 Chapter 2 Chapter 3 Chapter 4
Chapter 5 Chapter 6 Chapter 7 Chapter 8
Chapter 9 Chapter 10 Chapter 11 Chapte

Adolfo Muller
UTEID: am58987
February 25, 2015
Take Home Exam 1
1.
Fastest to slowest: T3(n) -> T1(n) -> T2(n)
2. We can use a version of Kruskals Algorithm, but instead of inserting edges from E in
order of increasing cost, we add the edges in order of d

Adolfo Muller
UTEID: am58987
February 25, 2015
Take Home Exam 1
1.
Fastest to slowest: T3(n) -> T1(n) -> T2(n)
2. We can use a version of Kruskals Algorithm, but instead of inserting edges from E in
order of increasing cost, we add the edges in order of d

CS377P Programming for Performance
Homework 3
Due: September 22, 2015, 7PM
Submit your answers as a PDF le.
1
Compilers
Use gcc-4.8 for the questions in this section. This is the default gcc on UTCS machines.
To obtain a listing, use gcc -g -Wa,-ahlscd=x.

CS 331: Algorithms and Complexity (Fall 2015)
Unique numbers: 50690, 50695, 50700, 50705, 50710, 50715
Assignment 1
Due on Wednesday, September 9th , by 11.59pm
Problem 1 (15 points)
(a) (5 points) Arrange the following list of functions in increasing ord

CS 331: Algorithms and Complexity (Fall 2015)
Unique numbers: 50690, 50695, 50700, 50705, 50710, 50715
Assignment 2
Due on Thursday, September 17th , by 11.59pm
Problem 1 (10 points)
(a) (5 points) Let T be a tree such that every node in T has 2 children.

Brian Leppez
bal893
Nandakumar
02/02/2015
What I Have Lived For
After 95 years of life, there are several things that I can attest I lived for. I have
lived in 5 different countries and visited all continents in the world. I can give credit to
my parents

Algorithms Study Guide Exam 1
1) Chapter 3 Graphs
a) 3.1 Basic Definitions and Applications
i) Any of the 2 imply the third
(1) G is connected
(2) G does not have a cycle
(3) G has n-1 edges
b) 3.2 Graph Connectivity and Graph Traversal
i) Breadth first s

THE DIVINE COMEDY
THE VISION
of
PARADISE, PURGATORY, AND HELL
BY
DANTE ALIGHIERI
COMPLETE ON-LINE INDEX
TRANSLATED BY
THE REV. H. F. CARY, M.A.
Illustrated by M. Gustave Dor
Click on Any Image to Enlarge It
DOWNLOAD
DOWNLOAD INSTRUCTIONS:
Click on the

Title
Size (kb)
Total
Words
N
Distinct
Words
M
Time with
SortedSet
(sec)
Time with
UnsortedSet
(sec)
The Divine
Comedy
23
3556
1123
0.0329
.0234
Beowulf
The Prince
Frankenstein
11.08x
1.16x
1.44x
11.88x
1.24x
1.47x
10.3x
0.73x
1.43x
98.29x
.77x
1.96x
65x

Lecture 6
Quicksort
6.1 Quicksort
Quicksort(A[p.r])
Divide: ? A[p.r] ? A[p.q-1] ? A[q+1.r]
p
r
x
A
A[p.q-1]
A
q
x
A[q+1.r]
pivot
Conquer: ? A[p.q-1] ? A[q+1.r] ?
Combine: ?
Quicksort
2
Quicksort(A, p, r)
1 If p < r then
2
q Partition(A, p, r)
3
Quicksort(

Datalog
Logical Rules Recursion
1
Logic As a Query Language
x Ifthen logical rules have been used in many systems. x Nonrecursive rules are equivalent to the core relational algebra. x Recursive rules extend relational algebra have been used to add recurs

Adolfo Muller
am58987
Bruno Veiga
bsv259
Assignment5
March 11, 2015
1. Given a sequence of supply values cfw_s1, s2, . , sn where each si
represents a supply value for a specific week, the subproblems would
be which company to choose for each ith week.
At

Adolfo Muller
am58987
Bruno Veiga
bsv259
Assignment4
March 4, 2015
1. Let n be the number of samples you are given, and let the whole set of samples
given be cfw_s1, s2, . sn denoted by si at each index. We'll begin our divide
and conquer algorithm by div

Title
Size (kb)
Total
Words
Distinct
Words
Time with
SortedSet
(sec)
Time with
UnsortedSe
t (sec)
Beowulf
Franken
255
42259
11572
3.234
Time
with
SortedSe
t (sec)
1.525
Beowulf
* CS314 SortedSet: *
Time to add the elements in the text to this set: elapsed