Computer Science 124:
Introductory Programming

     Department of Mathematics and Computer Science
     Hobart and William Smith Colleges

     Fall, 1998.

     Instructor:  David J. Eck.

     Monday, Wednesday, Friday, 12:00--1:10 PM, in Room Lansing 300.
     Lab: Tuesday, 11:00--1:00, in the Gulick Microcomputer Classroom.

About The Course

Computer Science 124 is an introduction to programming. Programming is only one part of computer science, but it is the most basic and most central part. This course has no prerequisites, although a general familiarity with computers will certainly be helpful. (If you are worried about not having enough background for this course, you might consider taking Computer Science 100 instead. CPSC 100 is a general survey of computer science.)

Many different languages are used for writing computer programs. Some of the most important are C, C++, Pascal, BASIC, FORTRAN, Ada, Lisp, Smalltalk, Prolog, and Java. It is impossible to learn all the different programming languages. Fortunately, it is possible to learn principles and general techniques of programming that can be applied no matter what language you write in. Although you will work with a specific language, you should try not to lose sight of the general ideas.

In this course, we will use the Java programming language, one of the newest languages. While C++ is still the language used for most "serious" programming, Java has becoming surprisingly popular in the three years since its release. Java is, in fact, very similar to C++, but it leaves out a lot of the complexity. Java is actually a good starting point for the beginning programmer, even if the ultimate goal is to use C++. Furthermore, Java has its own advantages. It has a few important features that C++ lacks, and it was designed from the beginning to be part of a modern, networked computing environment.

Instead of a regular textbook for this course, we will use an on-line text that I wrote for this course. The version we are using this term has been significantly revised and updated since the last time the text was used, in Winter 1998. I urge you to read the text on-line. However, I will put two printouts of the complete text on reserve in the library for those of you who would like to read a hard copy without printing it out yourself. I will also put several Java reference books on reserve.

(Note to Seniors on fulfilling requirements: This course fulfills a distribution requirement in the natural sciences. It does not, however, fulfill the lab requirement in the natural sciences. Even though the course has a "lab" it is not an experimental science lab in the usual sense.)

Computer Labs

This course has a lab component. For the duration of the course, you will have an account on the computer "" which will be used in the lab and for programming assignments. In the first lab, you'll learn how to access this account and how to use the programming environment that it provides. Labs will be held Tuesdays from 11:00 AM to 1:00 PM in the Microcomputer Classroom on the second floor of Gulick Hall. Weekly lab worksheets will be posted on the World Wide Web at

For each lab (except the last), you will turn in a "lab report". In each lab, there will be a few questions for you to answer and/or programming problems for you to solve. Your lab report will consist of your answers to these exercises. It is quite possible that you will not finish all the exercises during the Tuesday lab period. That is to be expected. Completing the lab exercises is part of your homework for the course.

You should work on each lab with a partner (although I will not stop you from working alone). You have the option of turning in a single lab report for you and your lab partner, or turning in an individual report. If you and your partner turn in a single report, you will receive the same grade.

Although I do not take attendance in regular classes, I do take attendance in lab. Ordinarily, you must be present at lab to get full credit for the lab report. If you miss a lab without a good excuse, I will still accept a lab report, but only for half-credit. (If you have some good reason for missing a lab, discuss it with me -- in advance if possible.)

Lab reports are always due on the Monday following the lab. Please turn your lab reports in on time. I will accept a lab report up to one week after it is due, but I will deduct 20% from its grade. I will not accept lab reports that are more than one week late.

Programming Assignments

In addition to lab reports, there will be several individual programming assignments. I encourage you to ask me for advice, hints, and help on the assignments. But you are not permitted to work with other students, discuss your programs with them, or look at their programs. (You should also avoid leaving copies of your work where other students might find it!) For the last of these programming assignments, I might allow students to work in groups.

Programming assignments that are turned in up to one week late will lose 20% of their grades as a penalty. Programs will not be accepted later than one week after they are due. Even if your program is not complete or not working properly, you should still turn it in to receive partial credit.

Tests and Quizzes

There will be two in-class tests in addition to a final exam. The tests will be given on Wednesday, October 7 and on Wednesday, November 4. The final exam is scheduled for Wednesday, March 18, at 1:30 PM; it will be given in our regular classroom (Lansing 300). It will be comprehensive, covering material from the entire term, with some emphasis on material covered during the last two weeks of class.

There will also be seven fifteen-minute quizzes, which will be given at the end of class on each Wednesday except for the first Wednesday of the term and the two Wednesdays when there are tests. It is extremely important to keep up with the material in this course, and I have found that weekly quizzes help students to do so. The lowest of your quiz grades will be dropped.

If you miss a quiz or test without a very good excuse, you will receive a grade of zero. If you think you have an excuse for missing the quiz or test, please discuss it with me, in advance if possible. If I judge that your excuse is reasonable, I will -- depending on the circumstances -- either give you a make-up quiz or test or I will average your other grades so that the missing grade does not count against you.


Your numerical grade for the course will be determined as follows:

             First Test:               15%
             Second Test:              15%
             Final Exam:               20%
             Quizzes:                  15%
             Lab Reports:              20%
             Programming Assignments:  15%

My scale for converting numerical grades into letter grades is:

             A:  90% to 100%
             B:  80% to 89%
             C:  65% to 79%
             D:  50% to 64%
             F:  less than 50%

Grades near the bottom or top of a range are modified by a minus or plus. I follow this scale fairly strictly, although I occasionally "curve" a test by adding some points to each person's score, if I judge that the original grades on the test do not accurately reflect the performance of students in the class.

Office Hours, E-mail, WWW

My office is room 301 in Lansing Hall, just next door to our regular classroom. My office phone extension is 3398. I am on campus most days, and you are welcome to come in anytime you can find me there. I will announce office hours and post them on my office door as soon as my schedule is determined, but note that your office visits are certainly not restricted to my regular office hours!

My e-mail address is ECK (or over the Internet). E-mail is good way to communicate with me, since I usually answer messages the day I receive them. You already have an account on the Colleges' main computer,, that you can use to send and receive e-mail. If you don't know the password for that account, you should contact Barry Jones in Williams Hall.

The "home page" for this course on the World Wide Web is located at (If you don't know what that means, you will soon!) This page will contain links to the on-line notes for the course, other sources of Java information, solutions to tests and quizzes, and more.

David Eck, 31 July 1998