M,F 2:30, Hollister B14. Start 24 Jan
or
M,F 3:35, Hollister B14. Start 24 Jan
or
M,F 2:30, Hollister B14. Start 06 Mar

CS1130: Transition to OO --Lecture sections

Spring 2012

Instructors: David Gries and Walker White

Announcements

10 Jan About labs
10 Jan Can't open the DrJava jar file
10 Jan Can't use Javadoc? Look here
10 Jan Using VideoNote
10 Jan CMS (course management system)
10 Jan Make extensions visible on your PC
10 Jan Seeing consultants, TAs, Gries
10 Jan Assert statement

About labs. The weekly lab takes place at 3 times, always in Hollister B14, and you can attend any one of them:

2:30PM, 3:35PM, 7:00PM

Attendance at labs is not mandatory, but it is STRONGLY encouraged because in the lab you will (1) definitely get the work done in a timely manner, (2) be able to ask a TA/consultant for help, and (3) be in a room with others who are having the same issues as you.

However, you MUST complete the lab and show it to a TA or consultant by the end of the week; otherwise, you are in danger of getting a U for the course. We will be reasonable about this issue, as long as you are reasonable about it.

Can't use Javadoc. A number of student cannot use the javadoc button in DrJava on their computer. It usually is a PC running windows 7, and some Ecclipse software is on the computer --for example, the ECCLIPSE compiler is being used in DrJava; look at the compiler pane. Some students have been able to fix this by downloading and installing the JDK. Look here to see how to do that.

[Note. To run Java one needs a JRE: Jave Runtime Environment. To compile Java programs and do other things, one needs a JDK: Java Development Kit.]

VideoNote You can see lectures of a previous version CS 1110 at www.cs.cornell.edu/videonote/cornell. The first 5 weeks of CS 1110 cover the OO portion of Java, much as we do on CS 1130. Along with the video comes a table of contents; click on an item and the video changes immediately to the place corresponding to the item you clicked.

Can't open the DrJava jar file. When you double-click on the DrJava jar file, that application is supposed to open up. However, there may be a problem with your Windows Operating system, especially if it is WIndows 7. If you have this problem, try visiting this website and downloading and installing application JarFix:

www.softpedia.com/get/Others/Miscellaneous/Jarfix.shtml

CMS (Course management system). We use the CS-designed "course management system" to manage assignments, tests, etc. The CMS for this course is at this URL: http://cms.csuglab.cornell.edu/. It is course

CS 1130lec (Staff) Transition to Object-Oriented Programming (Lectures)

When you visit the site, you will have to give your Cornell netid and password. The CMS was populated with students enrolled in the course on the evening of 24 January. If you are not enrolled in the the CMS, email Maria Witlox Mpr13@cornell.edu and ask her to enroll you. Make sure you tell her

Fix your PCs so that extensions (like .java and .doc) ALWAYS appear. To do this, do the following: Open an explorer window. Use menu item Tools / Click on Folder Options. Click the view tab. Uncheck the box "Hide extensions for known file types".

Seeing consultants, TAs, Gries

Check here for office hours of TAs and Gries.

The TAs have office hours. If you need some conceptual help of any kind, go the the TAs during their office hours. Choose any TA whose office hours are convenient for you; you don't have to limit yourself to your Section TA.

You can make an appointment for a one-on-one session with any TA. Contact the TA.

Consultants for CS1110 hold hours in the green room of the ACCEL Lab, which you get to through the Engineering Library in Carpenter Hall. Here is the schedule for the consultants in the ACCEL Lab.

You may spend a good deal of time programming there. The consultants are there to answer your questions. If you need help downloading and setting up DrJava, if you have a misunderstanding on an assignment, if you are having trouble debugging a program —in all such matters, ask the consultants for a quick answer. However, they will not write your program for you.

Assert statements

In Java, an assert statement like:

assert 0 <= d && d <= 99;

has the form "assert<boolean expression> ;". It is executed as follows: evaluate the <boolean expression>; if it is false, terminate execution with an assert-exception error message (if it is true, do nothing).

In the case of truncateTo5, the assert statement is the same as the precondition. Therefore, if the precondition is false and execution of the assert statement terminates the program, you have an error --either your program incorrectly calls truncateTo5, so you have an error in your program, or perhaps you incorrectly called it in the interactions pane.

Some people advocate leaving assert statements in a program to check for things like preconditions even after a program is completed and checked out, just in case there is one last bug that was not caught and might be caught this way.