Your CS1 Quiz 1 Preparation Tasklist
-
Textbook "An Introduction to OOP with Java"- C. Thomas Wu - Chapters
0, 1, 2, 3, 4.1,4.2 and 4.3
-
Introduction to Object-Oriented Programming (OOP)
-
Terminology - You should be able to define:
-
Object
-
Class
-
Differentiate between object and class
-
Identity
-
State
-
Property
-
Attribute
-
Behavior
-
Variables (instance variable versus class variable)
-
Constant
-
Method (instance method versus class method)
-
Operation
-
Invoking, Invocation
-
Benefits of Object-Oriented Programming (Know what these things mean)
-
Information Hiding/Data Abstraction
-
Modularity
-
Reuse
-
Class Hierarchy (Superclass, subclass)
-
Inheritance
-
What are the four basic types of methods?
-
How is invoking a method on an object similar to sending a message among
people?
-
What do the public and private access levels mean?
-
Basic Java
-
Terminology
-
Syntax
-
Semantics
-
Identifier (Java rules/our Java Coding Standard for identifiers)
-
Unicode
-
Literals
-
Cast
-
Assignment
-
Instantiation (and the role of "new")
-
Java Comments
-
// (Single line)
-
/* */ (Multiple line)
-
/** */ (Javadoc)
-
Primitive Types
-
What are the primitive types in Java?
-
How do they differ from reference types (objects) with respect to declaration
and memory allocation?
-
Be able to draw memory diagrams for primitive types and objects (upon declaration,
assignment, instantiation) see page 88, 89, 90 for e.g.
-
How are unprintable char's represented in Java code?
-
How are literals represented for float's, long's, etc.?
-
Constants
-
What is the modifier that means an identifier is a constant in Java?
-
Be able to write java code to declare/define a constant.
-
What does our Java Coding Standard dictate about identifiers for constants?
-
Variables
-
How are variables declared in Java?
-
What does our Java Coding Standard dictate about identifiers for variables?
-
Why do we need to instantiate reference variables (objects)?
-
When do we need to instantiate reference variables (objects) in Java?
-
How do we instantiate reference variables (objects) in Java?
-
Expressions
-
What four things affect how expressions are evaluated/stored in assignment
statements?
-
Operator Precedence - know the precedence among casting, parentheses, arithmetic
(* / % + - ++ --), assignment (= += -=)
-
Numberic Promotion -
-
How are mixed-mode expressions evaluated in Java?
-
Why is Java automatically able to promote a byte value to short,
int, or long, etc.?
-
Assignment Conversion - Why is Java automatically able to promote a byte
value to short, int, or long, etc. for assignment?
-
Casting Conversion - Why is casting necessary to assign a double
value to an int, etc.?
-
Be able to evaluate expressions keeping these four things in mind?
-
Assignment
-
What must be on the left hand side of an assignment statement?
-
Be able to tell whether or not an assignment statement is legal in java
and be able to tell why not, if it isn't!
-
Java Program Structure
-
We are writing applications using Java. What does an application in Java
look like? ( Template of a program in Java).
-
What is the syntax of for class declaration in a Java?
-
What is the syntax of the main class method declaration statement
in a Java application?
-
What is the main class method used for in a Java application? What
does it represent?
-
Invoking Methods
-
What is the Java syntax for invoking a method?
-
What does the dot (.) mean?
-
Where can you find out what information an object's method needs to do
its work in Java, i.e., where can you find out which arguments you must
provide?
Ankur M. Teredesai
Questions? amt@cs.rit.edu