David Scot Taylor
Dept. of Computer Science
San Jose State University
212 MacQuarrie Hall
Phone: (408) 924-5124 (email works better)
Email: david.taylor "at" sjsu.edu
Fall 2022 office hours:
Office hours will generally be in-person. When they are virtual, use this zoom link for zoom office hours, and you will enter the waiting room (I will see one at a time in the order you enter, occasionally updating the waiting room through chat about the size of the queue.)
The prerequisite courses are: Math 30, Math 42, and (CS46B in Java or (CS49J and CS46B)). You should show me grades for CS46B, Math30, and Math42, or their equivalents on a San Jose departmental course equivalence form. You must have a C- or better in each course. If you took CS46B elsewhere, you should also show me either proof that you have taken CS49J, or proof that your CS46B was in Java.
Prerequisite courses and what they covered:
CS46A: Introduction to programming, conditionals, iteration, and recursion.
CS46B: Stacks and queues, lists, dynamic arrays, binary search trees. Iteration over collections. Hashing. Seaching, elementary sorting. Big-O notation. Standard collection classes.
CS49J: Java programming language, if your CS46A/B were in a different language.
Math30: Ideally, you would have sequences and series (Math 31), but proof of Math 30 will suffice.
Math42: Sets, logic, proofs, induction, combinatorics, probability, and equivalence classes.
Introduction to Algorithms, 3rd Edition
Cormen, Leiserson, Rivest, and Stein
MIT Press, 2009
You can find errata (bug reports) for the book http://www.cs.dartmouth.edu/~thc/clrs-bugs/bugs-3e.php, for whichever printing of the book you get.
The following will be regularly assigned for time outside of class:
The purpose of the rote homework is to give you enough practice working on problems to either understand how to solve the problems, or at least to learn from solutions to those problems.
I encourage you to watch each video closely and carefully, pausing and taking notes if needed, before attempting homework on that video. If you don't do well on your first attempt at the homework, it indicates that you have not watched the video closely enough. This should give you some immediate feedback on whether or not you are watching the videos closely enough.
Canvas quizzes on the videos can (usually) be taken up to 5 times, but it is really your first attempt that will give you the most feedback on how well you understand the material. Using what would be a terrible homework assignment to give an example of the difference between the first attempt and later attempts: imagine that you are told to study the first 15 digits of pi. After doing that, if you were asked "What digit is in the is the 10 millionths position?" and you could answer that, it would give some indication that you had memorized the requested digits. On the other hand, if you got it wrong, and then looked at the digits of pi before taking a second attempt to answer the question correctly after memorizing the single digit requested, it would give little confidence that you knew any other digits of pi. Hopefully, your homework will be much more interesting than that example.
If, even after a second attempt at a Canvas homework, you still cannot get the correct answers, you can ask a classmate or somebody else to help you. You may not simply ask them for the answers. (That counts as academic dishonesty.) You can, on the other hand, have them walk you through the problem, step by step, until you get to an understanding of the answer. (For this course, that counts as diligence. You should understand your submitted answers, otherwise you need to spend more time on them.) Because the homework has a time limit for submission, you might want to take your 3rd attempt, if needed, to record the questions, so that you can do them with more time on your 4th attempt. You really shouldn't need a 5th attempt. The reason attempts are limited is to stop anybody from making blind submissions until they happen to get the correct answers.
In Spring 2021, I shifted away from written homework problems, but if I do have any, they will not be graded on correctness, but on whether or not it looks like an honest effort attempt was made to answer that problem. You may discuss problems with others, but anything other than superficial comments must be documented. You should not simply copy solutions, nor look for solutions (on the web or elsewhere), but if needed you can have somebody explain a problem to you in full, until you understand the solution. I might only return solutions for those problems for which you turn in evidence of putting in enough effort.
Note: The first homework assignments will be available until mid September, while the class enrollment is still being worked out. After that, homework will only be available until it is due. If you submit the homework, you will still be able to see it afterwards, but if you don't get around to looking at your homework before its due date, it won't be.
For both Canvas and written homework, you should do each homework, unless you are positive that you understand the topic so well that doing the homework would not be a good use of your time. And for those students? They should be the ones helping classmates to understand the material, as outlined in the two preceding paragraphs.
Success in this course is based on the expectation that students will spend, for each unit of credit, a minimum of 45 hours over the length of the course (normally three hours per unit per week) for instruction, preparation/studying, or course related activities, including but not limited to internships, labs, and clinical practica. Other course structures will have equivalent workload expectations as described in the syllabus.
Class partiticipation and feedback are very important to keep the course interesting. If I am covering material too slowly or quickly, or if I am not clearly explaining things, you must let me know. I prefer an interactive learning environment. If you disagree with something I say, speak up. Argue with me in front of the class. It will make the class better, and right or wrong, constructive interaction will not not hurt your grade. If you are correct, clearly my mistake should be corrected. If you are incorrect, probably I have not explained something clearly anyway, and at least half of the class is confused by it. Point it out right then and there. In cases of exceptional participation that seem to benefit the class as a whole, I reserve the right to improve a student's grade by up to 1/3 grade.
The class was designed to be taught in a `flipped' style: during class time, we will try to spend our time on interactive activities, rather than me lecturing to you. Many students feel like this style doesn't teach them as well. Research shows the strong possibility that it is more effective, even if students don't feel that way.
Per University Policy S16-9, university-wide policy information relevant to all courses, such as academic integrity, accommodations, etc. will be available on Office of Graduate and Undergraduate Programs’ Syllabus Information web page at http://www.sjsu.edu/gup/syllabusinfo/.
Instead, homework scores will be slightly used to set the curve for the exams: if the class as a whole is doing its homework, it might push the median test score towards the B- range, while if the class, as a whole, is not doing homework, it might push that median towards the C+ range.
I do not believe in assigning homework for the sake of assigning homework. If you understand the material without doing the homework, and the homework seems like a waste of time to you? In that case, your advanced understanding should be reflected by your performance on the rote tests (described below), with the expectation that you should do well on those tests. If you are in the top half of the class on those exams, your homework score will be ignored when setting the curve for the class, so your lack of homework will not hurt anybody. You are encouraged to help your classmates to learn the material, teaching it to them will help you to understand it even more.
Note, this policy should highly discourage students from cheating on homework: the (admittedly small) risk of being caught is balanced by the fact that your individual homework score will not help you individually, it will only play a very small role in setting the curve for the exams. Because your homework is only one of many homeworks used to set that curve, in cheating, you are taking all of the individual risk, while not reaping any individual reward. Additionally, you won't actually learn the material.
Due to the way that Canvas homework (multiple attempts) and written homework (graded on effort) are graded, the students making a real effort on homework should, as a whole, expect to get credit for a high percentage (90%?) of homework problems. Why should you do the homework? To learn the material. In some sense, homework is not optional, it is mandatory! It just doesn't happen to be part of your weighted course grade.
Rote Tests: There will be two in-class tests in the final weeks of the semester, that will test "rote" knowledge. You will be given a template for each exam a week in advance. These two exams combined will be scored on a (curved) scale from F to B-. (For the purpose of the class, you will just get a letter grade on the exam.) The curve will be based on both test performance, and my impression of the class performance as a whole (from homework and class interaction). You are expected to have a laptop computer, with the lockdown browser installed, that you can use for the exams.
You are expected to code your own programs, with at most minor help from others. Talking abstractly, while still trying to figure it out, with somebody else who is in the same situation, is fine. Sharing code is not, and this includes reading their code and retyping it, or having them dictate it to you. Do not look for premade solutions. Do not copy code. You should understand what your code does. If I ask you what something does in your code, and you don't understand why it is in your code or what it does? That is unacceptable, as it indicates that you are submitting work which is not your own. If you can get somebody to explain something to you in detail, to the point that you can understand and code it, that is okay. Your code will be checked for correctness, but graded on your ability to answer questions about it. It is possible to get credit for code that doesn't work. It is possible to not get credit for working code if you don't seem to understand what it does. This latter case may also be deemed academic dishonesty.
Although talking with others who are working on the problem is fine, do not directly tell somebody else how to do it if you have already figured out an algorithmic aspect and have yours working. If I think it is appropriate to give algorithmic hints, I will give them, that is my role as the instructor. They should be asking me, not you. Beyond scheduled office hours, I will spend over 100 hours this semester answering emails and holding additional office hours. Answering questions, based on the students situation, is a large part of my job as an instructor. I might not always give as direct an answer as you are hoping for, it depends on how far you have gotten, what you have tried, and what the deadlines are. But, I really do try to give you answers that will push you towards learning the material. Do not get the answers from someone who has already finished the programs.
I run a code plagiarism check at the end of the semester. Having conversations about copied code with students, and writing reports on academic integrity is one of the few parts of this job that I hate. Please don't put yourself, or me, into this position. There will be an assignment on Canvas to state that you understand the homework and program policy, and that you will not share code, nor use someone else's code.
You can make audio recordings of class for your own personal use. Perhaps you want to want to have my dulcet tones lull you to sleep at night instead of only during class, that is fine. Weird, but fine. Perhaps you want to torture your neighbors by blasting it on your porch, that is not fine: aside from possible violations of the Geneva Convention, recordings should not be reproduced, distributed, or publicly broadcasted. If you want to make video recordings, please discuss it with me.
Course material developed by the instructor is the intellectual property of the instructor and cannot be shared publicly without his/her approval. You may not publicly share or upload instructor generated material for this course such as exam questions, lecture notes, or homework solutions without instructor consent.
Subject to change
|Planned Topic||Actual Topic
or more detail
|August 22||Introductions, Administrivia, Warm-Up||find max|
|August 24||Finish Warm-Up, Start Application||2nd max
start: find highest indexed smaller # to left
|August 29||Defining Problems and Loop Invariants||finish: find highest indexed smaller # to left
Go over loop invariant example: linear search
|August 31||Asymptotic Notation Exercise||ordering 30 functions|
|September 7||Heap Lab: code review/lab exercise||No class today:
individual code review by appointment (through canvas)
for everyone either Tuesday September 6, Wednesday September 7, or Thursday, September 8.
|September 12||Recurrence Relations, Recursion Exercise||Is kth largest item in a heap larger than x?|
|September 14||Master Theorem or Sorting Questions?
|testing computer chips|
|September 19||Quicksort/select Questions?
|finish computer chip testing problem
|September 21||Problem Lower Bounds,
|September 26||Finish exercise from previous class,
lower bounds by reduction
|September 28||23-Tree Code Review||No class today:
individual code review by appointment
for everyone in the class, today or tomorrow
|October 3||Linear Sorts, Exercise|
|October 5||23-Tree Code Review||No class today:
individual code review by appointment
for everyone in the class, today or tomorrow
|October 10||Graph Exercise|
|October 12||Graph Exercises|
|October 17||Graph Exercise|
|October 19||Graph Exercise|
|October 26||DP Questions?|
|November 2||Rod Cutting, other Dynamic Programming Questions|
|November 7||Subset Sum Questions
Intro to NP
|November 14||NP decision vs. Optimization|
|November 16||Review Practice MT 1
Advanced Topic for Fun
|November 21||Review Practice MT 2
Advanced Topic for Fun
|November 28||Rote exam 1: through B-Trees (approx)|
|November 30||Rote exam 2: after B-Trees (approx)|
|December 5||Exams returned, Review for Final.|