CS1: Final
See the questions and answer sheet.
CS1: Lecture 38 – Slideshow
Dear students, A primary benefit of object-oriented design is that it helps us organize our programs coherently. We can put code and the data that it regularly processes together into the same chunk. Objects allow for the separation of concerns. Class A can focus on its task, and be very good at it. It can […]
CS1: Lecture 37 – Chat Continued
Dear students, Today we extend the networked chat application that we started writing last week. Beyond getting it functional, we’ll also give the client a graphical user interface (GUI). Java is one of the few languages that ships with a builtin windowing library. Dialogs If your program only prompts the user for simple input, like […]
CS1: Lecture 36 – Chatting with Sockets and Threads
Dear students, At the end of the semester, we have an opportunity to explore some new, crazy ideas. Next week we’ll have a look at graphical user interfaces. Today we’ll look at sockets and threads as we make a chat client. Sockets Computers got especially interesting when they gained the ability to talk to each […]
CS 148 Lab 12 – SplatBot
Welcome to lab 12! If you have checkpoints from the last lab to show your instructor or TA, do so immediately. No credit will be given if you have not already completed the work, nor will credit be given after the first 10 minutes of this lab. In this lab you will create a robot […]
CS 145 Lab 12 – SplatBot
Welcome to lab 12! If you have checkpoints from the last lab to show your instructor or TA, do so immediately. No credit will be given if you have not already completed the work, nor will credit be given after the first 10 minutes of this lab. In this lab you will create a robot […]
CS1: Midterm 2
See the questions and answer sheet.
CS1: Lecture 35 – Stopwatch
Dear students, As with methods, a primary benefit of object-oriented programming is code reuse. We can create a utility and use it over and over again, in many contexts. We will do just that by designing a Stopwatch class. Stopwatch We will use our stopwatch to time a few operations: the amount of time it […]
CS1: Lecture 34 – Reverse Engineering Objects
Dear students, In object-oriented programming, the programmer is really a writer of screenplays. Objects are our actors, which we orchestrate around the stage. We cue them to say certain things, have them interact with other objects, and shape them to have an identity that is all their own. Today, we’ll feel our away around the […]
CS 148 Lab 11 – Objects
Welcome to lab 11! If you have checkpoints from the last lab to show your instructor or TA, do so immediately. No credit will be given if you have not already completed the work, nor will credit be given after the first 10 minutes of this lab. In this lab you will create a bare-bones […]