CS1110 - Computer Science I    (Java)
Fall 2018 - Dr. Kaminski
Tentative Schedule
11/26/2018
ToDo links NOT LIVE til shortly before that date
lect/date
Tuesday lecture
lab
Thursday lecture
1

Aug 28-30
WMU Fall semester starts Wed Aug 29 NO
LABS
THIS
WEEK

(1st Week)
General Course Info   & Help/tutoring info

REFERENCE: 
Java Docs (basics)  web link

ToDo > >
2 - 3

Sep 4-6
Programming Basics
Java programs & NetBeans IDE
Console vs. GUI  I/O
  print & println methods
  JOptionPane class for user I/O
    input dialog box & output message box
concatenate [+]   (overloaded as add)
variables, data types
named constants (final)
 calculate [+ - * / %] & store data [=]
    / as integer divide vs. floating point divide
ToDo > >
LabEx1

Asgn 1
calc's,
userI/O
DUE: Sep
18/19/20
self-documenting code
input dialog box (JOptionPane)
data type conversions, casting
re-use variables
simple String methods
    (length,toUpperCase,toLowerCase)
combined arithmetic/asgn operators
store values for later vs. use right away
design:  S-IPO (Storage-Input/Processing/Output)
design:  incremental development

ToDo > >
4 - 5

Sep 11-13
algor: extract digits/chars from int/String
design:  develop algorithm using comments
Control Structures
control the flow #1:  decisions
     if, if/else
relational conditions
logical operators (! && ||)
algor: odd or even
algor: boolean flag
empty statements

ToDo > >
LabEx2
do Tues
ToDo task



stacked & nested if/else's
switch (for stack of if/else's)
more String class methods
    (compareTo, charAt)
printf (fancy, formatted output)
algor:  split number into sub-parts




ToDo > >
6 - 7

Sep 18-20
control the flow #2a:  while loop (event-controlled)
design:  continue condition vs. exit condition
userData validation
algor: running total
algor: processing an input data stream
    sentinel value vs. separate "quit"
design of loop str: read/process vs.process/read
do/while loop (postTest)
nested loop
design:  inside-out (bottom-up)
ToDo > >
LabEx3
do Tues
ToDo task


Asgn 2
if/else
looping

DUE: Oct
5 <<< NEW
algor: n, ave, min, max

control the flow #2b:
for loop (count-controlled)
nested loops
draw big characters
stacked / nested / controller
break (or continue) in loop - bad
    (control the flow #4)


ToDo > >
8 - 9

Sep 25-27
Modular Programming
control the flow #3: methods & calling
static methods
input parameters & return values
local variables
algor: split a String into chunks
Math class methods


ToDo > >
LabEx4
do Tues
ToDo task


i++ issues (vs. ++i)
methods in a separate class (& file)
modular design of earlier programs
algor design:  hierarchy of calls
    passing parameters
overloaded methods

more String methods (substring,
  replace,trim,pad,indexOf
)
static methods vs. String (OOP) methods

ToDo > >
10 - 11

Oct 2-4
File I/O
print to a file (& append to a file)
read from a file (and EOF detection)
Scanner class (for keyboard & file input)
read/process loop structures for files
Random class (random number generator)
    pass randomObject as parameter
    random seed, 2 RNGs
ToDo > >
LabEx5
do Tues
ToDo task

Asgn 3
methods
see Oct
2
ToDo
for A3 help

DUE: Oct
23/24/25
EXAM #1  (in lecture)
MUST BRING LAPTOP TO TAKE EXAM ON.
Windows-10 people - fix auto-update problem.
Covers everything since start of class, including
    material from textbook, lectures, examples,
    lab exercises, Thurs ToDo tasks & all asgns
    (A1 & A2) since the start of the semester,
EXCEPT not File I/O, Scanner, Random class.

ToDo > >
12 - 13

Oct 9-11
split a csv string
    & split
.csv file record (line) into fields
printf's format string as a re-usable variable
Arrays (Storage)
declare array, fill it with data: initializer list
using for loops with arrays
data & processing it:
    use as storage bin & data stream
parallel arrays
fill array with data - options:
    hardCode,  askUser,   [RNG]
    from calculations
from data file
ToDo > >
LabEx6
do Tues
ToDo task

Asgn 4
arrays
files
  csv,report
summary
   tables
DUE:
Oct 30/31
Nov 1

algor:  find Min/Max, find index of Min/Max,
    for stored data (as stream of data)
array of counters for categories
    call method to decide index
pass array as parameter
    pass-by-value vs. pass-by-reference
return array from a method
clean up input data read from a file
    more string processing methods
ASCII codes, cast to char/int, char arithmetic
algor:  3 approaches to print an E
 
ToDo > >
14

Oct 16-18
array size (vs. file size) options
    process
partly-filled array - n vs. length
    pass both array & n as parameters
special for loop for arrays

2-dim rectangular array
Is a string all digits?
    Character.isDigit boolean method
return as immediate exit
read file in a separate method
String.format method
ToDo > >
NO
LABS
THIS
WEEK

(Fall Break)
:
Fall Break

15 - 16

Oct 23-25
Arrays class sort & copyOf
algor:  reverse array, compare 2 arrays
Searching Arrays
linear search (1 match vs. multi-matches)
   
& binary search
      [issues regarding 2-conditions]
Big O notation (Order of complexity)
re-use a class (& its methods)
adapt code:  search String array
    search & use parallel arrays

ToDo > >
LabEx7
do Tues
ToDo task
copy & sort subArray
Sorting Arrays
algorithms:  insertion sort, selection sort
    swap
adapt code:  sort String/int/... array
    sort parallel arrays
design:  overloading
    vs. switch on specific code
Big O notation (Order of complexity)


ToDo > >
17 - 18

Oct 30-
    Nov 1
Object-Oriented Programming (OOP)
classes & objects (attributes & behaviors)
    [static methods vs. OOP class methods]
UML diagram for class design
public vs. private members
declaring/using multiple objects
getters & setters & constructors (overloaded)
toString & String.format methods

ToDo > >
LabEx8
do Tues
ToDo task


Asgn 5
parArrays
copy,select,
search,sort
subArrays
DUE: Nov
1
3/14/15
no lecture - sick day








ToDo > >
19 - 20

Nov 6-8
[do remaining proj from last week's ToDo's]
pass object as parameter
static variable to count objects
   
& its static getter
static constants in an OOP class
constructor as "mini-main"
read data from file (or user) to fill object
setters/getters for editing/translating
[auto-generate getters/setters/toString]
this
(to refer to inst. var. in setter
)
object is an array (or parallel arrays)
global (to this class) declarations
    (divide declaration into 2 parts)
SystemDate classes
ToDo > >
LabEx9
do Tues
ToDo task


EXAM #2  (in lecture)
MUST BRING LAPTOP TO TAKE EXAM ON.
Windows-10 people - fix auto-update problem.
Covers everything since start of class up to just
    before OOP, including
material from textbook,
    lectures, examples, in-lab exercises, Thurs
    ToDo programs & asgns
A1 - A4.






ToDo > >
21 - 22

Nov 13-15
[do remaining proj from last week's ToDo's]
array of objects (2-step declaration)
array of objects

   fill it from a data file

   sort it on a sortKey
   (use getter for sortKey value)
adapting sort algor. for objects
special getters & setters
2 levels of objects

ToDo > >
LabEx10
do Tues
ToDo task

Asgn 6
OOP
reUse obj

DUE: Nov
27/28/29
[do remaining proj from last lecture's ToDo's]
re-use just 1 object for file processing
more sort & search array of objects
approxEqual for doubles
return object from a method
[DEBUG & LOG boolean flags]



ToDo > >
23

Nov 20-22
[do remaining proj from last lecture's ToDo's]
OOP utilities:  copy object, compare 2 objects
OOP utilities:  copy object, compare 2 objects scope of variables & hiding/shadowing
    & global variables
other ways to declare an object
OOP utilities:  copy object, compare 2 objects
OOP utilities:  copy object, compare 2 objectsOOP utilities:  copy object, compare 2 objects this (for constructor calls a constructor)
copy constructor

algor:  add/remove from a sorted array
algor:  load & save:  file <--> array
[TESTING boolean flag]
ToDo > >
NO
LABS
THIS
WEEK

(Thanksgiving
Break)


program calls a program (test driver)     multiple programs in a project     main's parameter
Thanksgiving Break

(officially WMU break starts Wed. at noon)


24 - 25

Nov 27-29
[do remaining proj from last lecture's ToDo's][do remaining proj from last lecture's ToDo's]