cs is 4 4 u plate

CS 1112 Fall 2013

Students

Linkage










  finger print

  Class 15 — September 30, 2013
  Loop identification

Example

Worksheet

Agenda

  • Show even more programming familiarity by being all you can be using control constructs


  giga rollercoaster of iowa

  Class 14 — September 27, 2013
  Loopy

Example

Worksheet

Agenda

  • Show even more programming familiarity by being all you can be using control constructs




  looper movie poster

  Class 13 — February 11, 2013
  Loop spelled backwards is polo

Examples

Tell me more

Video

Agenda

  • For general problem solving we also need the ability to control how often actions are to be performed (looping).

  • Like Java most programming languages supplies three differation iteration statements: while, for, and do while. We are concerned today with the while statement.

Vocabulary

  • loop, iteration, counter variable, index variable, end of data, end of file

Slides

  • Looping: PDF and MOV formats


  pondering shoes at startupremarkable.com/wp-content/uploads/2012/01/Decision.jpg

  Class 12 — September 23, 2013
  You decide

Examples

Sidebar

Vocabulary

  • straight-line, test expression, statement block, local variable

Agenda

  • Some problem solving requires the ability to react — depending upon the circumstances different conditions need actions to be performed.

  • Java provides several statements that support decision making. We begin by considering the if statement.

  • The if statement uses a logical test expression to determine which of two actions should be performed.

Class 13 preparation

For today



  the little engine that could

  Class 11 — September 20, 2013
  I know you can

Examples

Class 12 preparation

Agenda

  • Strengthen problem solving skills by demonstrating chrestomathics in action

Change of plans

  • The collective best day for our class is to set Test 1 to Friday October 4.

For today

  • An open mind, closed-book, closed-notes, closed-web, three-minute quiz


  Ivory Tirupati

  Class 10 — September 18, 2013
  Listing

Exercises

Tell me more

Videos

Agenda

  • Sometimes when problem solving we need to represent a collection/list of objects. To support such processing Java provides the Collections Framework.

  • The Collections Framework consists both of a rich set of list representations and an extensive set algorithms for manipulating lists.

  • We consider two of the more important list representations — the ArrayList and HashMap. They support respectively ordered lists and associative lists.

  • We also consider some Collection algorithms for list manipulation.

Readings for next time

  • Chapter 4.1 — 4.4.

  olivia newton-john album cover

  Class 9 — September 16, 2013
  Do you like surprises?

Downloads

Let's get quizzical

Agenda

  • Show basic programming familiarity

Readings for next time

  • Chapters 3.

Videos




  wonder woman comic #1

  Class 8 — September 13, 2013
  String theory

Examples

Sidebar

Agenda

  • Gain familiarity with object manipulation using strings, colors, web pages, and windows as an exemplars

Readings for next time

  • Chapters 2 and 3.

Videos

Preparing for the future

Because we care


  rod stewart album cover

  Class 7 — September 11, 2013
  Every picture tells a story

Examples

Sidebar

Jelly Bean Quiz

  • Due Friday @ 2 PM. The quiz is available after class. Closest guess wins.

Agenda

  • Gain familiarity with object manipulation using graphics and files

Data files

Readings for next class

  • Section 3.2 – 3.4

Videos


 

  random numbers ala dilbert

  Class 6 — September 9, 2013
  Practice random acts of
  kindness

Examples

Reading for next class

  • Section 3.6 – 3.8

Tell me more

Videos

Agenda

  • A major course goal is to enable you to develop your own problem solving-specific representations.

  • I believe to accomplish this goal you need background experiences on the mechanics of object construction and manipulation.

  • The way I recommend is that you use objects built from some of the standard resources that are already available. Out of your experiences can come an understanding and appreciation for the object-oriented approach.

  • We will begin with graphical elements for creating windows and drawing shapes

Ponder

  • While the expression 5 < 10 < 12 makes sense mathematically, it is not a legal Java expression. Why is that? Hint: look at the expression while being cognizant of operator precedence

 

  necking giraffes

 Class 5 — September 6, 2013
 Fearlessly we march on

Examples

It's all about you

  • Please upload a photo of yourself suitable for anyone else to see. A passport-like photo will work best.

Readings for next class

  • Sections 3.1, 3.7 – 3.8

Haiku winner

  • A pure code virgin
    I thought Java was coffee
    Code gods, please bless me
      —  Mariah Gerrity

Agenda

Continue our exploration of the basics of problem solving — getting data, performing computation, and displaying information.

Along the way we will develop an appreciation

  • The java.lang class Math
  • Named constants
  • Expression evaluation and formulation
  • Operator precedence

Do unto others

Fun fact winners

  • A wombat's poop is cube shaped. (David Tondreau)

  • When a mantis shrimp gets hungry, it preys on hard shell fish such as clams. The shrimp strikes its club against the shell of the clam with enough force and velocity to literally boil the surrounding water as well as create a burst of light on impact. (Clarke Pietruszka)

  • While Liberty Island is under the jurisdiction of the state of New York, the island is located in New Jersey waters. So, technically speaking, the Statue of Liberty is located in the state of New Jersey, not the state of New York. (Melissa Murphy)


 

  jackalope

 Class 4 — September 4, 2013
 Hopping down the trail to computational  thinking

Examples

Even more examples for the interested student

Packets

  • The bookstore now has the readings and example packets ready.

  • It's okay if you got an old copy of the reading packet. However, you need a copy of the example packet for the current semester. I have made the PDF of the example packet available for download

Readings for next class

  • Complete Chapter 2

Epistles

Video

That's odd

Dana Wahoo is the owner of the Cavalier Ranch and has taken possession of 21 jackalopes. Dana directs the ranch manager to construct four new pens and enclose all of the jackalopes within the new pens. For the fun of it, Dana tells the manager to put an odd number of jackalopes in each pen.

Is it possible for the ranch manager to carry out Dana's instructions. If not, explain why. If it is, explain how.

Agenda

Sophisticated problem solving requires the ability to abstract. A very basic part of abstraction is ability to name a value and to manipulate the value through a referencing of its name.

Sophisticated problem solving also requires two-way communication — getting data and sending information back. Java provides class Scanner as a means for communicating with an input source.

  • Continue exploration of primitive types.
  • Introduce variables for naming locations in computer memory where values are stored.
  • Use definition statement to specify the name, type, and initial value associated with a variable.
  • Explore variable assignment.
  • Use Scanner to get input.
  • Practice program modification.


 

  congress

  Class 3 — September 2, 2013
 Representation without taxation

Examples

Readings for next class

  • Sections 2.1 – 2.7

Homework

Agenda

  • Expand our communication skills;
  • Introduce the different types of basics values that Java provides (in programming speak they are called the primitive types);
  • Introduce the notion of operator precedence;
  • Develop an appreciation for writing readable programs.
  • Stand up the first time I say wahoo.

Choo-choo

  • A model train is set up on a circular track. There are six telephone poles evenly spaced around the track. The train takes ten seconds to go from the first pole to the third pole. How long does it take to go all the away around? Why? [Based on an exercise from Crossing the river with dogs]

Time management

  • In further effort to improve your life overall and your studenthood in particular watch a time management video by Randy Pausch.

  • Randy gave this talk to us at UVA in full knowledge he had only a few months to live. Make time to this watch it by next Monday.



 


  grey's anatomy

  Class 2 — August 30, 2013
 Splaining

Today's artifacts

Future artifacts

Readings for next class

Turing test

Agenda

  • Convince everyone to become a computing major
  • Introduce terminology to which you should become accustomed
    • Class
    • Method
    • Comment 
    • Whitespace
    • Keyword  
    • public
    • class
    • void
    • Statement
    • Semicolon
    • Library
    • System
    • Dot operator
    • System.out
    • println()
    • Literal
    • String[]
    • Identifiers
    • Translation
    • Interpretation


 
  car engine mechanics

 Class 1 — August 28, 2013
 First day of the rest of your life

Agenda

  • Convince everyone to become a computing major

  • Appreciate the wisdom of the movie
         What about Bob?

  • Never, never, never click on this link!

  • Meet course personnel

  • Discuss syllabus and course mechanics

  • Ensure both a Java SDK and DrJava is installed on all laptops
  • Download and submit a program

Java example

Readings for next class

Are you an impostor?

  • I think not. Watch this video to be sure.

How many jelly beans are there?

jelly bean jar

Job interview fun

  • Suppose a job interviewer hands you a two-armed balancing scale and a bag with fifteen coins that may or may not be of equal weight.
  • The interviewer goes on to tell you that it is known that fourteen of the coins do weigh the same.
  • The interviewer then asks for an algorithm (list of steps) that minimizes your use of the scale in determining whether the coins are of equal weight. And if they are not identical, to identify the different coin.
  • The interviewer also says that only the scale can be used in determining the solution.
  • What is your algorithm?


tom petty album cover

The waiting is the hardest part

Important

Pledge

Readings

Practicing structured communication — haikuing

Software development

Important