CSI 310 Spring 2012

Link to current week

Syllabus and course policies.

Spring 2011 Offering's web site

This is the website for course assignments, notes and other resources. Blackboard is used for submitting homework, conducting discussions and tracking grades.

Free trial this semester for optionally using CodeMate to practice CS1 basics. 1/3 grade point bonus if you do 95% for the assigned questions! Get more information and the access code from Blackboard

General Resources

(UNDER CONSTRUCTION) Disk Drive I use in the Lectures (I'll try to update within 24 hrs of the lecture).

Week by week plan

What will happen in lectures:

  1. iClicker quizzes on reading and lecture attention, and non-graded surveys, that will count toward your grade!
  2. Live demos of programming in Java! Watch your professor get stuck on syntax errors and bugs!
  3. Think-pair-and-share to figure out how to do projects and other questions!
  4. Notes scribbled electronically by professor and presentation materials that you don't have to copy because they will go on the Web!
  5. Sometimes, cool, corny videos from UTube or visits to other cool web sites!
  6. Discussions to clear up confusion before getting frustrated at the computer!
  7. End of class quizzes or "minute papers" to see how well you learned: counts toward grade too!

Week 1

Jan. 27-29 GLOBAL GAME JAM...Join the Prof. and others..at Albany's instance of the Jam class! Early registration for only $10.00 1/24-1/27. $15.00 walk in. (Some meals are included) Or just show up for some of the time and watch!

Day Readings/Assignments/Topics Resources
Labs no labs first week; optional orientation Fri, 1/20 1:00PM-5:00PM in HU-25
C01 Thu Jan 19

Week 2

Jan. 27-29 GLOBAL GAME JAM...Join the Prof. and others..at Albany's instance of the Jam class! Early registration for only $10.00 1/24-1/27. $15.00 walk in. (Some meals are included.) Or just show up for some of the time and watch!

Readings:

Day Readings/Assignments/Topics Resources
Labs Lab Assignment

Get the java-sources for GE Data Structures, to replace your copy of book-classes from 201

Make sure you can run DrJava with the Data Structures version Picture class in Lab

Make sure you can copy, compile, and demontrate the OneCollageMaker program.

Begin to develop it into the TwoCollageMaker application; finish and submit on Blackboard by Sun. night.

OneCollageMaker.java

Tip: Use tiny images like the above two so that your answer Picture is small enough to fit entirely in your computer screen.

C02 Tue Jan 24
  • C02 Notes: From C01 with more added:
    • Understand what the problem is FIRST
    • Break big problems into steps..lecture shows several lists of steps.
    • Centered, bordered collage from 4 images project described briefly, number of Picture objects that must be made.
    • Two kinds of variables involved.
    • Breaking project problem into steps; simplifying some steps to begin.
C03 Thu Jan 26

Week 3

Readings:

Day Readings/Assignments/Topics Resources
Labs
  • Demonstrate in lab code to (1) instantiate many House objects and (2) refer to same and different House objects with the same and different House REFERENCE or POINTER variables.
  • Practice the principles communicated in the MadPhD video.
  • After lab, find them on your S: drive or ssh access to itsunix.albany.edu and upload a complete Java program to Blackboard for grading and credit.
C04 Tue Jan 31 Small images of numbers good for debugging Proj 1
C05 Thu Feb 2

Week 4

Readings:

Day Readings/Assignments/Topics: Resources
Labs
C06 Tue Feb 7

Lect06 Live coding directory used in lecture.

Resources for Proj 2, 3 and 4
Arrays

Wed Feb 8

Programming Project 1 DUE Wed, Feb. 8

C07 Thu Feb 9 Live coding directory used in lecture.

Week 5

Readings:

Day Readings/Assignments/Topics Resources
C08 Tue Feb 14
Labs

C09 Thu Feb 16
Sun Feb 19 Projects 2 and 3 DUE.

Week 6

Readings:

Day Readings/Assignments/Topics Resources
C10 Tue Feb 21
  1. Scribbles about the array solution
  2. Scribbles about the linked list solution

Directory used in Lecture--with demonstration completed (after class)
Labs Lab 05-06 Make your own Facebook. The Social Network movie
C11 Thu Feb 23
  1. Warmup Quiz
  2. Prototype for Project 05--download and RUN from a command line: java -jar Proj5Proto.jar
  3. Project 05 Assignment: Due March 3.
  4. Making a cursor move back is easier with a Doubly linked list. with cursor.
  5. Buggy list adding code quiz REDONE.
  6. Walk up to preceeding node before removing the current node (from G&E not done)
  7. Deleting a Node requires a finger to point to the Node before it (not shown)
Sun Feb 26 Project 4 DUE (cut middle, cut end, paste end with a linked list).

Week 7

Readings:

Day Readings/Assignments/Topics Resources
C12 Tue Feb 28 Doubly Linked List Stuff

Quiz:

  1. Quiz-question
  2. class Dnode definition needed for the quiz
Labs Lab 05-06 Make your own Facebook. The Social Network movie
C13 Thu Mar 1
Sat Mar 3 Project 5 Due

Week 8

Readings: Chapter 8 (Trees of Images) and Section 11.1 (Stacks). Post-midterm projects will use this content.

Day Readings/Assignments/Topics Resources
Labs Unix using and timing a sorting program.
C14 Tue Mar 6 Tip about stacks and local lifetime storage. Intro to scene graphs (GE Chapter 8)

Call tree scribbled for Cat in Hat Comes Back Part I.

C15 Thu Mar 8 MIDTERM EXAM Closed book, one 8 1/2 x 11 inch paper sheet of notes.

Week 9

Readings:

Day Readings/Assignments/Topics Resources
Labs
C16 Tue Mar 20 New Operations: Call and return. Illustrated with

code in ClickerSortingApplication.java and ClickerSortingEngine.java

C17 Thu Mar 22

Calls and Returns in SortingApplication analyzed with a call tree, also expression tree example and exceptional control flow

Selection Sort needed for current Lab 08

Lab 08: Part Two of the Unix Lab: Replace Collections sort with your own Selection Sort code, and repeat timing.

Week 10

Readings: See selected readings in Project 06 assignment.

Day Readings/Assignments/Topics Resources
Labs Lab09: Reverse-Engineer the Wolf Attack Movie

Patches to make it work!!

C18 Tue Mar 27 Project 06 ASSIGNMENT: Due April 7

Selection Sort explanation:

  1. Javi API Comparable
  2. First Swap
  3. Second swap, subsequent no-swap.

    Selection Sort explantion and clicker questions


Activation History tree for the Procrastination Program, including the recursive palendrome printer:

  1. procrastinationProgram.java
  2. procrastinatorsToDoList.java
  3. itemNode.java

Lecture notes.

Search for homo sapiens in NIH Taxonomy Tree Browser

The sorting project framework SW:

  1. Engine
  2. Program

Maybe ArrayList data structure (extensible array).

IBM's notes on Java "visibility" (public, private, protected, default explained)

Official Java Language Spec on "access control"

C19 Thu Mar 29 Recursive palendrome making method activation history and the calls and returns leading up to it

Code of the methods whose calls/returns were diagrammed.

Recursive view of palendrome making

How MERGESORT works: Steps 1 and 2

Step 3: non-recursive MERGE (different from MERGESORT)

Next class: The whole activation history for using MERGESORT to sort 8 numbers.

Week 11

Readings:

Day Readings/Assignments/Topics Resources
Labs No new lab this week (No classes Fri 4/6 and Mon 4/9)
C20 Tue Apr 3 MERGESORT Leading Question; question about returning right after step 3 of MERGESORT.

Ways to trace and understand recursion:

  1. Activation (call/return) history tree

    Tree for MERGESORTing 8 items.

  2. Stack of activation records (you have to erase or redraw after some return operations) WILL DO.
  3. Mathematical induction or "faith" (you have to obtain solutions to the recursively solved subproblems some other way, but it's good for design and for proving correctness. (EXPLAINED ORALLY--will provide notes)
C21 Thu Apr 5 The Java ArrayList and its generic partially-filled dynamically-extendable array.

Prepared slides on recursion, MERGESORT, Trees, etc.

Situation of the length 1 subarray

Ways 1 and 2 of indexing subarrays

SearchEngine.java (Binary Search case study)

Towers of Hanoi

Week 12

Readings: Text 10.3 and 10.4 (for lab and theory). For project: Chapter 8.

Day Readings/Assignments/Topics Resources
Labs Lab 10: searching/building binary search trees
C22 Tue Apr 10 Programming Assignment 7: G&E Scene Graph

MERGESORT method, make it return immediately after the three steps.

The Cat in the Hat Comes Back recursively.

Recursive code for printing a palendrome analyzed 3 ways: History tree, activation record stack, induction based on the recursive structure of a palendrome.

Binary search tree intro.

Prepared slides on recursion, MERGESORT, Trees, etc.

introducing the expression tree and use of stack in evaluating an expression.

C23 Thu Apr 12

The Java ArrayList and its generic partially-filled dynamically-extendable array.

Intro to readings 10.3-10.4

Paper by Chomsky

Search for homo sapiens in NIH Taxonomy Tree Browser

Binary Search Tree definition

How the stack tracks evaluating an expression recursively.

Towers of Hanoi

Week 13

Readings:

Day Readings/Assignments/Topics Resources
Labs Lab11: Recursive Pattern Matcher(.pdf)

Matcher.java download

C24 Tue Apr 17 Project 07 Notebook!

iClicker survey and Kinds of Tree Traversal

Post-Order traversal corresponds to evaluating an expression expressed by an expression tree with using a stack for storing intermediate results

C25 Thu Apr 19

Inorder drawn vertically.

Prefix and Postfix notation.

Evaluation of postfix expression using a stack.

Making a compiler One.

Towers of Hanoii.

Pattern Matching Lab tips

ArrayList

Why mergesort is fast (again?).

Postscript Language from Wikipedia

Postscript Language Specification

Week 14

Readings:

Day Readings/Assignments/Topics Resources
Labs Lab 12: Record running times for sorting (A) with insertion sort and (B) merge sort files of lengths ranging from really small to multi-millions of lines, so you get times up to several seconds. PLOT the times you get on (1) Linear Graph Paper and (2) Log-Log Graph Paper: Use the Log-Log paper to plot on one graph a HUGE RANGE of file sizes and sorting times. Your TA will grade how many of the required combinations of experiments you did and plotted.
C26 Tue Apr 24 Scene Graph Project Due 4/21

Last Project Assigned Due May 5

Maze Lectures

Language/Grammars/Trees (Lecture notes of Steve Pinker.)
C27 Thu Apr 26

Week 15

Readings:

Day Readings/Assignments/Topics Resources
Labs
C28 Tue May 1
  1. Kitware Flyer 1    Kitware Flyer 2      Wed., May 2 CCI-Women In Tech Meeting 4:00PM
  2. Doubly-Linked Lists and Extendable Partially Filled Arrays COMPARED
    1. Doubly-Linked Lists in Linux Kernel (struct list_head)

      Actual kernel code defining the list_head type

    2. Sketch of how list_heads are used.
    3. Table
    4. Algorithm for adding an item to an extendable array: the code under if is executed ONLY when there is no more room.
    5. Analysis of total time to add N items when the array is extended by one element each time (get O(N^2))
    6. The doubling strategy
    7. Analysis of total time to add N items when the array is extended by being doubled in size when it must be extended (get O(N), just like linked list).
    8. Table (now note information in the lower left corner.)
C29 Thu May 3 Slides.

Arrays vs ArrayLists (or extendable-partially-filled arrays)

Copying of old items is done sometimes (not always)

Tracing maze search with activation record stack.

Week 16

Current Mark

Readings: See the summary. Info from readings is included in the lecture notes, but you might want to read them for review.

Day Readings/Assignments/Topics Resources
Labs
C30 Tue May 8 Summary for studying for the FINAL EXAM!!

Please use the Blackboard discussion board for questions and answers of review, and email sdc to alert me to respond.

Final Exam May 15 10:30AM-12:30 in LC-19 Closed Book, one 8 1/2 x 11 paper sheet of notes.