(Latest Revision -- 04/05/01)
04/05/01: changed office hours
02/15/01: corrected room number for section #2 to P-113

Course Description
for Computer Programming II: CS 2500

TERM: Spring 2001

CLASS CODES:There are two sections this semester:

20664 CS 2500 001 Computer Programming II Lec 3.0 MW 10:10-11:08 P-101
20665 CS 2502 001 Computer Programming II Lab 0.0  F 10:10-11:08 P-101

21721 CS 2500 002 Computer Programming II Lec 3.0 TR 09:40-10:37 P-113
21722 CS 2502 002 Computer Programming II Lab 0.0 TR 10:37-11:07 P-113
INSTRUCTOR: John Sarraille, Professor of Computer Science

OFFICE: P-286, Professional Schools Building, Cal State Stanislaus

OFFICE HOURS: MWF 12:20-13:20; T-Th 11:15-12:15; or by appointment

E-MAIL: john@ishi.csustan.edu

HOMEPAGE: http://www.cs.csustan.edu/~john/jsHomepage.html


I will make course documents, assignments, supplements, and so on available on the world wide web. To access the on-line CS 3100 materials, you can open the URL:


There is also a miscellaneous collection of information that you may want to use from time to time. It is located here:



You have to be adequately prepared for taking this course, CS 2500. Check with me if you have not passed Computer Programming I (CS 1500), or the equivalent.


The main aim of this course is for you to acquire the knowledge, skills, and experience needed to solve programming problems correctly, efficiently, independently, and on time. It will not be easy, but you will do well if you are patient and persistent.

Some specific goals are to learn about simple data structures, common algorithms, analyzing the efficiency of algorithms, designing programs that are easy to check and maintain, the basics of testing and debugging, self-reliance, and dealing with the inherent uncertainties and complexities of today's computing systems.

Other aims of this course include learning to use advanced C++ features such as structures, classes, pointers, arrays, and files; learning to use Sun workstations effectively; and gaining facility with jove, a plain-text editor that is useful for editing program source files.


Data Abstraction and Problem Solving with C++: walls and mirrors (2nd edition), by Carrano, Helman, and Veroff, published by Addison Wesley, ISBN 0-201-87402-4.

Just Enough Unix (3rd edition), by Paul K. Andersen, published by McGraw-Hill, ISBN 0-07-230297-6.


You should also consider getting a more comprehensive Unix book. Here are a couple of possibilities:

UNIX in a Nutshell: System V Edition, 3rd Edition, by Arnold Robbins, published by O'Reilly & Associates, ISBN 1-56592-427-4.

UNIX System V: A Practical Guide, 3/e, by Mark G. Sobell, published by Addison Wesley, ISBN 0-8053-7565-1.


We will be covering chapters 1-4, 6-7, and 10 of Carrano (program design, recursion, information hiding, lists, stacks, queues, and trees). In Andersen we will cover chapters 1-3, 5-12, 17-22, 25, 27-31, and appendices A, B, D, E, and G (introduction to Unix, Common Desktop Environment, Unix file system, tutorial on files, directories, file manager, Unix shell, text editors, networking, e-mail, remote login, ftp, startup files, shell scripts, programming under Unix, terminal, man pages, permissions, write, talk, and make).

See the schedule for weekly reading assignments.


For technical reasons, students in this class are required to sign up separately for CS 2500 (lecture) and CS 2502 (lab). However, each class session will be some mixture of laboratory and lecture activities. Mainly the purpose of class sessions is twofold: to help students absorb the readings and related material, and to help them complete the programming assignments.

Almost every time class meets, whatever day it is, we will be in P-101. Always come to P-101 for class unless I have previously announced that we will meet in the computer lab.

Students are responsible for doing programming assignments outside of class time. Doing the assignments can fill up a lot of hours. To keep the pace, you will need to "work smart." In any case, expect to spend about ten hours per week on this class, in addition to class time.

My expectation is that everyone will attend all the classes and keep current with everything that is happening in class. I will keep track of attendance.


The course has two main components: programs, and exams. There will be three quizzes, an optional comprehensive final exam, and about five programming assignments.

To pass the course you must receive a passing average in both the programming component and the exam component. You also must turn in a working solution to every programming problem. If you do all this, then your course grade will be determined by giving a weight of 60% to your exam average (20% per exam) and 40% to your programming assignment average (about 8% per program).

If you get a failing exam average, a failing average on your programs, or if you fail to turn in a program before the final deadline, you don't pass CS 2500 this term.


Under ideal circumstances you will not need to take the final exam. However, if you miss a quiz or if you want to improve your average on the exam component of the course, you may choose to take the final exam.

The final exam is penalty-free. If your score on the final exam is higher than your lowest quiz score, then the final exam will replace your lowest quiz score: it will count 20% of your grade in the course and your two highest quiz scores will each count 20%. If your score on the final exam is equal to or lower than your lowest quiz score, then nothing will change: your course grade will be computed just as it would have been if you did not take the final exam.


Our text is C++ oriented, and I will present most code samples in C++. If you want to do a programming assignment in a different computer language, basically I am willing to accept that, but you must speak with me in advance and reach an agreement on some ground rules.


I will require you to design each program using a top-down design methodology, modular data structures, and information hiding. You will use the top-down method to design the instructions of your program, the data structures, the documentation, and the test data. A programmer using the top-down method develops the program level-by-level. The programmer starts with a very simple first-level program design, and works down, step-by-step, to more detailed levels.

I will sometimes require you to turn in two or three "levels" of your programming assignments so that I can check your progress in employing the top-down design method. For example, for a programming assignment worth 8% of your overall grade, the top and second levels might count 2% each and the final level 4%.


Get started early on your assignments. That way, if you run into difficulty, you can seek help in class and/or office hours in a timely fashion.

I will assess a late penalty of 10% credit per calendar day (including holidays and weekends) on programming assignments turned in between one and five days late. I will not accept programming assignments late more than 5 days.

We can have class discussions about due dates and I may be willing to move a due date back if the class can justify this to my satisfaction. If you are uncomfortable with a scheduled due date, please bring this to my attention as soon as possible, and not at the last minute.

If you cannot finish an assignment on time, please turn in whatever you have done. It may be possible to get up to about half credit on an unfinished program, depending on the quality of the work and the circumstances.

To "survive" in a class like this, you may need to put aside "foolish pride," stubbornness, and/or shyness. If you are failing to make progress on some aspect of an assignment, seek help from me promptly. You may speak to me after class or during my office hours. You may send me a message by e-mail. You are entitled to get help this way. Please don't subvert your chances of success by sitting and "spinning your wheels" until it is too late.

I'm sorry but if you fail to turn in just one program by the fifth day after the due date, you fail CS 2500. You will not be allowed to continue in the class. I will not make exceptions.


I hope to be accessible and helpful to you during this course. I want you to get as much as possible out of it.

Remember, we are a team and you are a key player. Read everything I assign ASAP, and read with care. Read difficult material more than once! Attend all classes. Pay close attention. Take notes. Review your notes before each class. Get started on assignments early. Do a little each day, and bring your questions and problems concerning these assignments to class each day.

Finish assignments and reading on time. Do what you can to keep class discussion lively and to the point. Reply to questions. Ask questions and make remarks if you feel you have something to add, or if you feel something needs to be explained better.


Assignments: When your purpose is to clarify or to reach an understanding of program specifications, you may discuss programming assignments with other people, including your classmates, as much as you like. You may also freely discuss the relative merits of various general approaches to designing and engineering solutions.

You are permitted to use algorithms or segments of code from any of the published printed matter in our library, from our course text, or from any programming textbooks to which you have access.

You may ask me for help and hints. Ask in class, so that everyone has a chance to benefit from the discussion.

You may not discuss or give away any program code segments.

You may not accept program code or accept help from any source other than those described above.

Exams: You must write your exams with no discussion or help from anyone. The one exception is that you are allowed to come forward and ask me to clarify the meaning of a test question, if you wish. It will be up to me to decide how to answer, or whether to answer at all. I will tell the class any new information that arises from such an exchange.

Penalties: If there is compelling evidence that homework, programs, or tests were not done according to the above criteria, I will withhold credit.


You need to have an account that gives you access to all the Computer Science Department Sun Ultra 10 and Sun Ultra 30 computers. The computers have a network file system, which means you get the same home directory and "computing environment," regardless of which Sun Ultra you log on to.

If you don't have access to the Ultra's, tell me right away. If you aren't sure, tell me right away. I'll give you a form to fill out, and I'll see to it that you get a username and password.

We will have a special lab session to teach you what you need to know in order to use the Ultra's for class assignments.

The Ultra's and other CS computers are located in the Computer Science Lab: P-288. P-288 is in the Professional Schools Building (aka Demergasso-Bava Hall), in the extreme northwest corner of the north wing.

I will test the programs that you write for this course by compiling and executing them on a Sun Ultra. Therefore you must write programs that will compile and run without errors on these machines. If you are accustomed to a different computing environment, you will have to be careful about this.

Generally, CS Department workstations are available for access and use on a 24-hour basis. However campus computer labs do not remain open at all hours. Therefore sometimes network and modem connections are the only means available for connecting to a workstation. For more information about network and modem connections, see the sections below entitled "MODEM CONNECTIONS" and "INTERNET CONNECTIONS". Also see the course document entitled loginDirections.

P-288 will be open basically mid-morning until about 5:00 p.m.. During these times, you can be physically present in the CS Department Lab while using a department computer. This can be very beneficial because you then have the opportunity to work and communicate with fellow students and members of the staff and faculty.

Due to budgetary constraints beyond our control, the hours during which P-288 is open are subject to change on short notice. Please check the postings of the lab hours at the entrance to the lab or in the "message of the day" that is printed on your screen when you log on to your Sun Ultra account.

Incidentally, the CS Department often seeks volunteers and work-study students to help keep the lab open longer hours. For further information, ask our system administrator, Julie Gorman: P-288C, 667-3273, julie@eos.csustan.edu

While you are in the CS Lab, you will be able to access Sun Ultra workstations by logging in directly at the console, or by using telnet from some other kind of computer in the lab, such as a Macintosh or a "Wintel".

Telnet makes it possible for many people to use a given workstation simultaneously. We will have a demonstration of how to get a telnet connection. (You can probably get help just by asking someone in the lab.) You can also access the Sun Ultra's via a telnet connection from most any computer on the campus local network, such as those in P-106, P-120, L-125 and L-145. Generally those labs are open during the same hours that the campus library is open. Please check postings at the labs or ask lab personnel in order to get further information about lab hours. Lab assistants (wearing red vests) should be able to show you how to telnet to a CS Department workstation.


Some phone numbers for making modem connections are: from Turlock 669-9834; toll-free from Modesto 523-2173; toll-free from Merced 723-2810; and toll-free from Stockton 467-5399. There has been recent discussion of discontinuing the availability of some of these connections. Check with the computer center's (OIT's) help desk to get the latest information. The help desk is in L-150, and the telephone number is 667-3687.


You may want to purchase Internet connectivity. This is not a requirement and not necessary for success, but it can be a great time-saver and a convenience once you have gotten past the hurdle of setting everything up.

There are several Internet service providers (ISP's) that serve this area. Chances are that members of the class can make good recommendations. We can devote some time to this topic in class.

One can find many ISP's by using the site: http://thelist.internet.com. ISP's also advertise in the yellow pages and in newspapers.

If you get an Internet connection, make sure you get telnet and ftp capability. This will allow you to log in remotely to your computer account at the college and also transfer files back and forth. For doing telnet and ftp, you may need to get some special add-on software. For more information about this, read the telnet and ftp help sheet. For additional information, ask me or the CS Lab Administrator, Julie Gorman.