
C
CM
MS
SC
C
1
13
31
1:
:
C
Ch
ha
ap
pt
te
er
r
2
28
8
F
Fi
in
na
al
l
R
Re
ev
vi
ie
ew
w:
:
W
Wh
ha
at
t
y
yo
ou
u
l
le
ea
ar
rn
ne
ed
d
t
th
hi
is
s
s
se
em
me
es
st
te
er
r
T
Th
he
e
“
“B
Bi
ig
g
P
Pi
ic
ct
tu
ur
re
e”
”
Object Oriented Programming: In this course we began an introduction to programming
from an object-oriented approach.
– Java was the primary vehicle we used for programming.
– This will continue in CMSC 132 where you will learn more of the finer points of object-
oriented design.
Major Topics:
Basic Elements: types, variables, constants, operators, I/O
Control Flow: if-else, switch, while, do-while, for
Classes:
• object instances and references
• instance and class data
• methods
Arrays: 1-dim, multi-dim, ragged arrays, programming
Inheritance: overriding, late-binding, interfaces
B
Ba
as
si
ic
c
E
El
le
em
me
en
nt
ts
s
(
(o
of
f
J
Ja
av
va
a)
)
Basic Elements:
– Basic file structure: File name, class structure, comments
– Identifiers: Naming rules and naming conventions.
– Primitive types:
• boolean
• Integral types: byte, (char), short, int, long
• Floating point types: float, double
– Strings: and common String operators/methods.
– Specifying constants: true, ‘x’, 12, 3124L, 3.14159e-10
– Operators: Their meaning and precedence rules.
Possible Questions:
– Are these valid identifier names? $_Pasta_Fazool_22
– Operator precedence: x * 2 + y --
– Is a cast needed? float y = 2.0;