CMPSC-F131-A

Section: 
A
Instructor: 
Zinoviev, Dmitry
Meeting Information
Semester: 
Fall 2009
Days and Times: 
MWF 11:00AM - 11:50AM, F 10:00AM - 10:50AM
Room: 
F615
Final exam
Time: 
Tue, 12/15/2009 - 10:30am12:20pm
Location: 
F615

Textbook

Prerequisite

  • This course has no prerequisites.

Description

Computer Science I (CSI) is the first Computer Science major course (and as such is a prerequisite to any other CS major course). The purpose of CSI is to teach the foundations of Computer Science and mainly of computer programming (yes, Computer Science is much more than computer programming).

Our language of choice is Java originally developed by Sun Microsystems and released in 1995. Java belongs to the C family of languages that also includes C itself, C++, C# (pronounced "see sharp"), and other more exotic languages. By the end of the semester students will be able to develop sizable (one page or longer) computer programs in the Java language.

Efficient Java program development requires an Integrated Development Environment (IDE) - a collection of tools that make it possible to edit, compile, and debug Java programs. Our IDE of choice is Eclipse. Eclipse is free and available for many operating systems, including Microsoft Windows (all flavors), Linux, Unix, and Mac OS X.

In addition to programming, the course teaches students how to work with Linux. Linux is a free operating system that is used in many other major CS courses taught at our department.By the end of the semesters students will be able to manage their files and directories and use simple editing and deveopment tools (as well as Eclipse).

Evaluation and Grading

Homework

There are 10 homework assignments, given approximately once a week.

Each assignment includes paper-and-pencil (P&P) exercises and programming exercises in Java. As a courtesy, please either e-mail your solutions to the (P&P) exercises or type and print them. All programs must be submitted electronically. If a program consists of more than one file, all files related to one program must be archived using tar and gzip.

Use workspace 'cs131' to hold your programs.

I do not accept late papers and programs, unless a documented medical condition prevented you from submitting them on time. Please submit as much as you have done by the deadline, even if the assignment has not been completed, and explain how much has not been done and why.

You are responsible for your homework. All homework must be done independently. A close similarity of homework papers or programs submitted by different students is a sufficient cause not to grade all of them.

Tests

There will be two 75-minute intermediate tests and the final exam. The tests include both theory questions and programming exercises. All tests are closed book, closed notes.

There are positively no makeup tests (unless you had a documented medical condition). The University policy requires that to request a make-up final exam, you have to write a petition to the Dean of Students.

Grade Calculation

The estimation of your course grade is calculated using the following weights:

  1. Homework assignments - 30%
  2. Midterm I - 25%
  3. Midterm II - 25%
  4. The final exam - 20%

I reserve the right to amend your final grade, based on my own judgement (which, in turn, is based on my observations of your class participation).

Your grades (including the exam grades) will be posted at CampusCruiser.

Tentative Schedule

I reserve the right to amend the schedule, based on the progress or lack thereof. Yellow lines denote Friday morning classes.

 

Class Topic Reading Homework
9/9 Logistics. What is computer programming about? From machine code to assembler to Java. Virtual machines. Ch. 1 HW1 OUT. EX: 1.2, 1.3, 1.6. PP: 1.1, 1.3, 1.7, 1.8.
9/11 Editing, compiling, interpreting. Java foundations. Comments, identifiers, keywords. Objects. Structure of a simple class.    
9/11 Lab (meets in F438). Intro to Linux: login, logout, desktop. Intro to Eclipse: creating a workspace, a project, a class. Compiling and running a Java program. print vs println.    




9/14 The first Java program(s). Characters and character strings. Ch. 2  
9/16 Escape sequences. Concatenation. Von Neumann computer    
9/18 Variables. Expressions.   HW1 IN.
9/18 Lab (meets in F438): Unix commmands. Primitive data types   HW2 OUT. EX: 2.5, 2.6, 2.7, 2.10. PP: 2.3, 2.5, 2.7, 2.9.




9/21 Data convertions. Operators    
9/23 Input (Scanner). Packages. Ch. 3  
9/25 Classes and objects. New. Aliases   HW2 IN.
9/25 Class String   HW3 OUT. EX: 3.2, 3.4, 3.6, 3.7, 3.10. PP: 3.1, 3.3, 3.6.




9/28 Classes Math, Random; formatting    
9/30 Boxing/unboxing; enumerated data types; Examples 1 and 2    
10/2 Relational and logical operators Ch. 4 HW3 IN.
10/2 Condition statements; data comparision   HW4 OUT. EX: 4.2, 4.5, 4.7, 4.8. PP: 4.1, 4.4, 4.5, 4.8.




10/5 Cascaded "if" and "switch"    
10/7 "while" and "do-while" loops; infinite and nested loops    
10/9 Iterators; reading from files    
10/9 Input validation; "for" loops    




10/12 No class    
10/14 Review   HW4 IN (due on 10/14!). HW5 OUT. EX: 4.9, 4.12, 4.16, 4.21. PP: 4.10 (b,d), 4.12, 4.15, 4.18.
10/16 TEST 1    
10/16 TEST 1  




10/19 Classes revisited. Class design  Ch. 5    
10/21 Class design; visibility    
10/23 Method design; paremeter passing; return statement   HW5 IN
10/23 Static methods and data; instance and local data   HW6 OUT. EX: 5.4, 5.7, 5.11, 5.15, 5.20. PP: 5.1, 5.4, 5.7, 5.9.




10/26 UML diagram of a Java class; generalization; call by value; keyword "this"; method overloading    
10/28 Point and Rectangle examples    
10/30 Arrays: definition, selection Ch. 7 HW6 IN
10/30 Arrays: definition, selection   HW7 OUT. EX: 5.22-5.23, 5.25-5.26, 5.32 (see page 191). PP: 5.13, lab problems 1 and 2




11/2 Arrays: dynamic and static initialization; arrays as iterators; passing as parameters    
11/4 xxxxx    
11/6 xxxxx    
11/6 xxxxx    




11/9 Arrays: 2D arrays; varargs    
11/11 No class   HW7 IN. HW8 OUT. EX: 7.1, 7.4, 7.6, 7.7. PP: 7.3, 7.4, 7.7, 7.8
11/13 GUIs. Components, events, and actions. JButton, JLabel, JPanel Ch. 6  
11/13 Calculator example    




11/16 Calculator example    
11/18 Review    
11/20 Calculator example: finite state machines    
11/20 TEST 2    




11/23 JTextField, JPasswordField, JCheckBox   HW8 IN. HW9 OUT. EX: 6.2, 6.4, 6.12, 6.13 PP: 6.4, 6.8, 6.15; EXTRA CREDIT: modify the calculator program: (1) add division and negation (+/-; your program should report an ERROR on the display if division by 0 is attempted) (2) add full floating point support (including the "." button)
11/25 No class    
11/27 No class    




11/30 JRadioButton, ButtonGroup, JSlider    
12/2 JComboBox   HW9 IN. HW10 OUT. EX: 6.6. PP: 6.8, 6.13, 6.17 (do not implement the dialog box, ignore the second part of the assignment).
12/4 Layout managers    
12/4 Drawing in Java    




12/7 Drawing in Java    
12/9 Review    HW10 IN




12/15 Final exam (10:30AM-12:20PM)    

Attendance Policy

An attendance sheet circulates each class session. It is the students' responsibility to make sure that they sign the attendance sheet. Attendance is tabulated and graded. Under other equal circumstances, students with good attendance will be assigned higher final grades than students with poor attendance.