23
Course Resources • An Introduction to Object-Oriented Programming with Java by Wu • Data Structures & Other Objects Using Java by Main • Course web page: • http:\\www.cs.rit.edu\~cs2 • Course News group: • news:\\news.cs.rit.edu\ rit.cs.courses.0603.232

Course Resources

  • Upload
    nerina

  • View
    19

  • Download
    0

Embed Size (px)

DESCRIPTION

Course Resources. An Introduction to Object-Oriented Programming with Java by Wu Data Structures & Other Objects Using Java by Main Course web page: http:\\www.cs.rit.edu\~cs2 Course News group: news:\\news.cs.rit.edu\rit.cs.courses.0603.232. Course Resources. Lecture Notes - PowerPoint PPT Presentation

Citation preview

Page 1: Course Resources

Course Resources

• An Introduction to Object-Oriented Programming with Java by Wu

• Data Structures & Other Objects Using Java by Main

• Course web page: • http:\\www.cs.rit.edu\~cs2

• Course News group:• news:\\news.cs.rit.edu\rit.cs.courses.0603.232

Page 2: Course Resources

Course Resources

• Lecture Notes• http:\\www.cs.rit.edu\~jaa\Cs2-Winter00\home.html

• Unix Beginners Guide• Lecture and Lab Instructors• Teaching Assistants• Lab Assistants

Page 3: Course Resources

Structure

• Lecture - • MTW 2:00PM to 2:50PM 07-1205

• Lab • Office Hours

• Wednesdays 3:30 – 5:30PM• Thursdays 1 - 3PM• 10-1184

Page 4: Course Resources

Schedule

• Weekly reading assignments that correspond to lecture and lab assignments.

• Weekly lab assignments.• Two Programming Projects.• Two in class exams.• Final Exam.

Page 5: Course Resources

Grade determination

• Final Exam 30%• Labs 20%• In Class Exams 30%• Projects 20%

Page 6: Course Resources

Lab Assignments• Pre-lab activities and reading.• Grading

• Each lab is worth 30 points• Final lab grade is the average of your

highest 9 individual lab grades.• A 0 given for cheating will not be dropped.

• Grades will be returned via e-mail.

Page 7: Course Resources

Lab Assignments

• Due Dates:• Lab assignments are due at the end of the

day two days prior to your next scheduled lab.

• No make-ups for missed labs.• No late submissions are accepted.• Submission for most of your labs will be

electronic.

Page 8: Course Resources

In Class Exams

• There are 2 in class exams.• 50 minutes each.• Closed book.• Must be on time for exams.

• Exams WILL NOT be given out to those who are late to class.

• No make-ups are given for exams.• Exams are not given early.

Page 9: Course Resources

In Class Exams• Grading:

• Each question will have a point total associated with it.

• This total will be determined when the exam is created.

• If you miss an exam or arrive late for an exam, you receive a 0.

• Your final exam grade is the average of both exam scores.

• A 0 given for cheating will not be dropped.

Page 10: Course Resources

Final Exam

• Date will be announced.• A common exam will be given to all

sections at the same time.• No make-ups nor early examination.

• Comprehensive Coverage:• All reading material, all lecture material, and

all lab material.

Page 11: Course Resources

Programming Projects• Two programming projects will be required

during the quarter.• Programming projects are larger than lab

assignments.• You will be given about 4 weeks to complete

project assignments.

• Programming projects have a specified due date and a late due date.• If your project is late,there are consequences.

Page 12: Course Resources

Programming Projects

• Both programming projects are to be individual efforts unless otherwise specified.• You may discuss the project with someone

but the project must be your individual contribution.

• Each project assignment must compile and show reasonable effort or you will automatically fail the course.

Page 13: Course Resources

Academic Honesty

• You may receive help with Labs but each lab submission must demonstrate significant intellectual contribute by you.

• You may discuss projects with others but each project must be your own effort.

• Any help you receive must be acknowledged.

Page 14: Course Resources

Academic Honesty• Remember

• The first time you are caught cheating, you will receive a zero for the assignment and a letter will go into your academic folder.

• The second time you are caught cheating, you will receive an F for the course, even if it is a different course from the first instance.

• An additional letter will be placed in your academic folder.

• The third time, you are referred to judicial affairs.

Page 15: Course Resources

Old Business

• Review solutions for Queue and Stack questions on CS1 final exam.

Page 16: Course Resources

Type Wrapper Classes

• Type wrapper classes are a class where each instance holds a primitive data type.• Type wrapper classes inherit from the

class Object.• Instances of type wrapper classes may be

stored into data structures that hold data of type Object.

Page 17: Course Resources

Type Wrapper Classes

• A Type Wrapper class exists for each primitive data type. • Double, Integer, Float, Byte, Character,

Boolean.

Page 18: Course Resources

Integer Class

• The Integer class allows us to store data of type int into an object.• Constructor: Integer(int value)• The method to access the data value is

called intValue() and it returns an int data type.

Page 19: Course Resources

Integer Class

• Example:int I = 42;

int j;

Integer example(i);

j = example.intValue();

• The *Value() method exists for each Type Wrapper class, see Main page 246.

Page 20: Course Resources

Composition

• In CS1 you learned how to define your own Classes that created user defined data types.• You also learned to create instances of

these classes inside of other classes. Using your user defined classes in this manner is called Composition.

Page 21: Course Resources

Inheritance

• Java also permits you to use your user defined classes to create programs using inheritance.

Page 22: Course Resources

Inheritance• All classes in Java are organized into a

class hierarchy.• The highest level classes are very general

and the lower level classes are more specific.

• The lower level classes are based upon the higher level classes and inherit the higher level class instance variables and methods. They also contain their own instance variables and methods beyond the higher level class definition.

Page 23: Course Resources

Inheritance• The higher level classes are called

Superclasses and the new or lower level classes are called the subclasses.• A subclass can always become a superclass

• Inheritance allows you to define certain behaviours once and then to reuse those behaviours over and over again in the subclasses. This is called reusability.