slides

advertisement
COMS S1007
Object-Oriented Programming
and Design in Java
July 8, 2008
Teaching staff
• Chris Murphy
– cmurphy@cs.columbia.edu
– Office hours: Tues 3-5pm or by appointment,
608 CEPSR
• Swapneel Sheth
– swapneel@cs.columbia.edu
– Office hours: Thurs 3-5pm, 608 CEPSR
• Starting next week
About the course
• The second course for majors in computer
science. A rigorous treatment of objectoriented concepts using Java as an
example language.
• Development of sound programming and
design skills, problem solving and
modeling of real world problems from
science, engineering, and economics
using the object-oriented paradigm.
Prerequisites
• COMS W1004 or AP Computer Science
with a grade of 4 or 5
• Completion of an Intro to Java course at
another university
• You should be familiar with basic Java
concepts and programming principles
• You should be comfortable writing a 200line program with 4-5 classes
Course homepage
http://www.cs.columbia.edu/~cmurphy/1007
• Please check the course homepage
frequently for important announcements
and changes to the reading assignments
CourseWorks
http://courseworks.columbia.edu/
• Check the “Discussion” section for
questions related to the homeworks
• Check the “Gradebook” to make sure our
records match your own
Grading
• Homeworks: 35%
• Final project: 25%
• Final exam: 40%
• These are “guidelines” for the final grade
Homeworks
• There will be three homework assignments
this semester
– You generally have one week to complete them
• Homeworks will be posted on the course
homepage
• Late submissions are not allowed!
Final Project
• The final project can be thought of as a
“big” homework assignment
• As part of Homework #3, you will write a
proposal that describes the functionality
and the design of your application
• At the end of the course, you will demo
your project to the class
Final Exam
• An in-class final exam will be held on the
last day of class: Wednesday, August 14
• Exam covers material from readings and
lectures (so come to class!)
• There are no make-up exams!
Textbook
• Cay Horstmann
Big Java, Third Edition
• Available at CU Bookstore or Amazon
• Chapter numbers are different from the
Second Edition
Syllabus
• Topics covered include:
– Advanced Java features
– Principles of object-oriented design
– Good programming practices
– Basic graphics
– Data structures
• Check the course homepage for assigned
readings for each lecture
Academic honesty
• Please familiarize yourself with the Computer
Science Department’s policy:
http://www.cs.columbia.edu/education/honesty
• It is YOUR responsibility to read and adhere to
the policy
Today
• Review of Java basics
– Third edition: Chapters 1-7 except “T”
(Testing) and “G” (Graphics) sections
Development Environments
• Eclipse
– http://www.eclipse.org
• NetBeans
– http://www.netbeans.org
• JGrasp
– http://www.jgrasp.org
Chapters 2-3: Using Objects &
Implementing Classes
• Objects and classes
• Methods
• Constructors
• Accessors & mutators
• Object references
• The Java API: String, Scanner
Chapter 4: Data Types
• The 8 primitive Java data types
• Constants
• Assignment, Increment, Decrement
• Math functions
Chapters 5-6: Decisions and
Iteration
• The “if” statement
• Boolean expressions
• “while”, “do/while”, and “for” loops
• Generating random numbers
Chapter 7: Arrays & ArrayLists
• Arrays
– Everything must be same type
– Fixed size
• ArrayLists
– Address above limitations of Arrays
– Important methods: add, get, contains, remove
Download