Midterm #1 Topics

Computers
- Hardware, Software, CPU, Virtual Machines
- Source code, compiler, byte code
- Different kinds of memory

Java
- Statements, expressions
- Local variables
- Primitive variable types
- Code blocks ({})
- Naming conventions
- Constants, literals
- Variable scope, duration
- Assignment (=)
- Operators (new, +, -, *, /, %, ==, !=, <, <=, >, >=, &&, ||, !)
- Conditionals (if, else)
- Loops (while)

Classes
- Class vs. object
- Object instantiation (construction)
- Class variables (instance variables)
- Reference variable type
- Memory diagrams with reference variables and objects
- Objects with no references, garbage collection
- Methods
- Constructors
- Parameters, arguments, pass-by-value
- Return types, return values

Problem Solving
- Break down a problem into a solution with a sequence of statements.

Exam Rules

a. 50 minutes exam (in discussion not lecture)
b. Closed book/closed notebooks, no calculators allowed.
c. Please use pencil.
d. Format:

i. Some short answer conceptual questions.
ii. Some small code analysis questions (identify syntax and logical errors).
iii. Write some small code segments.