Getting a Computer
Advice on Testing
CS350, Section 1 — Fall Quarter 2015
Tuesday and Thursday 14:00–15:50
FAB 092 (at the bottom of the stairwell in the
Professor Andrew Black
503 725 2411
Office: FAB 115–10
Office hours: Tuesday 16:00–17:00 and
Thursday 11:00–noon. It's also fine to just
wander by my office and see if I'm free.
To set up an appointment at an alternative
time, please use the telephone.
Office hours: Mon & Wed 13:30–14:30
Location: FAB 120 “Fish Bowl”
This course follows on from CS 311 — which looks
at what can and cannot be computed — by looking
closely at the complexity of computing the
stuff that is
computable. That means how much time, and sometimes
how much space, an algorithm takes. Why does this
matter, when computers are so fast? Because we often
want to solve large instances of certain problems, and
the time taken by some algorithms is exponential in
the size of the problem instance. What that means is:
if we choose an naive algorithm, solving the problem
might take more time than the expected lifetime of the
The approach of the course is mathematical: much of
it is about deriving formulae for the expected running
time of algorithms. However, there will also be some
programming assignments, including a programming
Upon the successful completion of this class,
students will be able to:
1. Analyze the running time and space complexity of
2. Use the big Oh notation. (e.g., O(n
3. Describe how to prove the correctness of an
4. Use the mathematical techniques required to prove
the time complexity of a program/algorithm (e.g.,
limits and sums of series.)
5. Perform inductive proofs.
6. Prove and apply the Master Theorem.
7. Describe the notions of P, NP, NPC, and NP-hard.
8. Compare the rates of growth of functions.
9. Apply algorithmic complexity principles in the
design of programs.
10. Design divide and conquer and dynamic programming
The required book is Introduction to the
Design and Analysis of Algorithms (3rd
Edition) by Anany Levitin. Addison
Wesley; ISBN-10: 0132316811
ISBN-13: 978-0132316811. There is
also a Kindle Edition, which is a bit cheaper,
but I think that it contains page images and
works only on larger-screen devices.
I will be assigning reading from this book,
and I will not be repeating the
material that you have read as lectures.
Instead, we will be using the time in class to
solve problems and deal with issues that you
raise as a result of your reading. This puts
the onus on you to speak up if you don't
understand the readings.
NB: In addition to the textbook, I'm
requiring you to purchase a clicker or a clicker
This book, Introduction to Algorithms,
by Thomas Cormen, Charles Leiserson, Ronald
Rivest, and Clifford Stein, has been used at
PSU in the past. It's a great reference, but
is significantly harder to read than Levitin.
It's also organized by problem class, rather
than by algorithm class.
The book is intended for a graduate course.
It takes a mathematical approach, focusing
much more than Levitin on proof of correctness
of the algorithms. I'm listing it here as
resource that you may like to own,
particularly if you can find a used
copy. I will not be assigning
reading from this book.
I recommend that you come to class, that you participate
actively, and that you take notes. The act
of taking notes (even if you never look at them
again!) is a powerful learning aid. I will
generally make any visual aids, code samples, etc.
that I used in class available on the web, but
these are not a substitute for being in
class and taking notes. If you do have to miss a
class, say because of illness or work-related
travel, you are responsible for getting notes and
finding out what went on in class from another
Student Response Devices
To encourage participation, I'm going to be using
student response devices in class, and part of the
grade will depend on your responding to the
in-class questions. (Whether or not you
answer correctly won't affect your
grade.) You have a choice with respect how
you respond to the in-class questions.
- Buy a ResponseCard NXT device.
The best place to get this is probably the PSU
bookstore, because then you can get it
immediately. You can also buy them
directly from Turning Technologies, at https://store.turningtechnologies.com.
Our "School code" is PSU1, and
it, the price is $40. (Without, the price
is $66.) Of course, you may also be able
to find a used device cheaper.
- Buy a license to ResponseWare.
This is a cloud-based system that you can access
from a web browser on your laptop, or from your
smartphone. A one-year license
costs $19.95; a four-year license is $34.99.
The best way to buy this is online: go to
and enter code PSU1 when
asked for your "school code".
If you are using ResponseWare
, you can vote
using a web browser (on a laptop, tablet, or
smartphone), or you can download the (free) ResponseWare
app for iPhone and Android from the app store.
I regret asking you to spend yet more money,
but the educational research result are in:
interactive classes using these devices really do
improve learning. I also regret that you may have
already bought a different brand of device for
Reading listed in the syllabus for each week
should be completed before coming to
class. I will check on the completion of reading
assignments by various means: oral or written
quizzes in class, written summaries, discussion
(web-based or in class), etc. Anything in a
reading assignment is fair game for an exam
Online Questions & Discussions
There will not be a class mailing list; instead,
we will be using Piazza for class
discussion. This system is designed to get you
help fast and efficiently: from classmates, the
TA, and the instructor. Rather than emailing
questions to the teaching staff, I encourage you
to post your questions on Piazza. If you have any
problems or feedback for the developers of Piazza,
Sign up at: piazza.com/pdx/fall2015/cs350
Class link: piazza.com/pdx/fall2015/cs350/home
Handwritten or printed assignments are due at the
start of class. I will accept assignments up
to three days late, for a 10% penalty in
points. So homeworks due on Thursday can be
turned in late on Friday, Saturday, or Sunday;
homeworks due on Tuesday can be turned in on
Wednesday, Thursday or Friday. (In cases of
authenticated sickness, I'll accept homework late,
without penalty, beyond this limit.)
We do sometimes make mistakes. If you believe
that we have not graded your assignment according
to the published grading scheme, please let the
instructor know in writing or by email
within 1 week of the assignment being returned to
you. Be specific as to why you think that the
grading is inconsistent. We will then
re-grade the whole assignment; the second grading
will stand, whether it is higher or lower than the
If you are a student with a disability in need of
academic accommodations, you should first register
with the Disability
Resource Center, and then notify the
instructor to arrange for support services.
If you have a medical or a family emergency and
must miss an exam, let me know, if at all possible
before the exam, and I will work with you
to find an alternative. Other reasons for absence
such as scheduled travel are not
emergencies and are not cause for a
Passing the Course
Every assignment in the course is connected to a
learning objective. It is therefore important that
you make an honest attempt to complete them all. A
score of less than 20% on any assignment indicates
that you have not met this condition, and is
sufficient cause for failing the course. That
means an F, at the discretion of the instructor.
Students are at university for two reasons: to learn
stuff, and to gain a credential. Because the
credential is important to many of our students, part
of my role as a professor is to make sure that it has
value. This means ensuring that the degree is awarded
only to those students who have mastered the material
in my course.
I have every sympathy for those who have difficulty
with the material and seek the assistance of the
instructor, the TA or their fellow students. I have no
sympathy at all for those who decide that the fastest
way to a degree is to cheat. I have been responsible
for having cheating students dismissed from the
university in the past, and I will not hesitate to
seek to have cheaters dismissed in the future.
The most common form of academic dishonesty is
representing the work of others as your own. In all
written material, you are allowed, indeed expected, to
build on others’ work, but must do so in a way that
makes it absolutely clear what part of the work is
your own, and what part is due to others. You do
this by citing the prior work. If you reproduce
someone else’s work in a way that makes it appear to
be yours, you are guilty of plagiarism—in other words,
Cheating on an assignment or exam will result
in an automatic zero grade for that piece of work,
and the initiation of disciplinary action at the
Cheating and collaboration
I encourage collaboration on certain assignments; I
will not tolerate cheating. Where is the line between
First, if an assignment is explicitly set up as a
team assignment, you are of course allowed
— indeed, required — to collaborate with the
members of your team. In this case I will generally
require only one completed piece of work to be turned
in from the team as a whole.
For individual assignments, I encourage you to talk
about the problem with your fellow students. During
such discussion, you may even write something,
perhaps the code of a critical method, or a key step
in a proof, as a group. If you do this, there is a
danger that you might reproduce that group work as if
it were your own. To guard against this danger, do the
following: after the group session, destroy any notes
or code that you may have brought away with you. Then
go and do something else for an hour or two: go for a
walk or a bike ride, play your favorite sport, go to
the gym: do something to flush your short-term memory.
Then sit down with a blank sheet of paper or a blank
computer workspace and start work on your own
solution. If you have a photographic memory or
otherwise won't be able to forget what you have seen
someone else write, then don't participate in
collaborative problem-solving sessions.
If I see the same code or assignment from two or more
students I will take this as evidence that these
guidelines have been ignored, and will assign a grade
of zero to all of the students involved.
Please refer to http://www.pdx.edu/dos/codeofconduct
for details of the general PSU Student Code of
Method of assessment
The following represents my present intention; I
reserve the right to vary the grade distribution if it
seems necessary or desirable.
Five graded assignments, each worth
5%. The assignment with the lowest
score for each student will be dropped from
the final grade computation.
Week of 25th October, in class
||Monday 16th March,
Further details will be made
available. Some of these points will
be awarded for the project proposal.
For participation in class and
Most recently modified on Friday 2 January 2015 at 13:15
Andrew P. Black