Course Lectures, Readings & Resources

Sample Final: Sample for Final exam : Final solution: 1.1 - 1.4 - 1.5 - 2 - 3- 4 - 5 - 6 - 7

Midterm #2 review

Midterm # 1 Review:
(Please note that Nested loops, Random number generator, Do-while topics will NOT be included on this midterm)

 

Helpful resources:

online tutorials and Java resources

Free PowerPoint viewer for class notes

Class

Date

Topic & Class Programs

Class Lectures

1 1/22 Course Introduction

Reading: Chapter 1
Course Introduction

2 1/24

Java Introduction
First programs: Welcome1, Welcome2 & Welcome3

 


Introduction to Java Lecture
3 1/29

  Lab Session: Class will be held at the ITS Lab at 14 Washington Place (between Green And Mercer streets). We will meet in the Lab. Make sure you are on time!



Lab assignment (assignment # 0, due 2/5 by midnight)

4 1/31

Using "Variables": int, double, & float: addition

Data entry from the keyboard using JOptionpane class:Welcome3 and Welcome4, text, integers,


Reading: Chapter 2

Variables

5 2/5

Arithmetic Operators: division, division2, average, the area of a circle

 



 
6 2/7

Using the"Mod" operator % to separate digits: DivMod.txt,ReverseDigits.txt,

Control Structure (comparisons):
Selection statements: if/else statements:
Even & odd numbers, comparing numbers



Mathematical operators

7 2/12

if statements: Even & odd numbers, comparing numbers

Using the"Mod" operator % to separate digits: DivMod.txt,ReverseDigits.txt, date

Using boolean variables : BoolTest.txt



Reading: Chapter 3
Boolean types; If & else statemnts
8 2/14

Using boolean variables:TruthTables
Conditional.txt

Review if statements: dice_using_if

Switch selection: dice_using_switch ,switch example 2 ,

 

Conditions, logical operators, and switch statement
2/18 Holiday
 
9 2/19

Data entry from the keyboard using JOptionpane class with char and String datatypes:text

Using Char: char_entry, Char.txt, CharInput.txt, directions_using_if, directions_using_switch

Using length() to get the number of characters in the string: char using length

Shortcut operators: pre_post increment , Shortcut_operators

For loops: For1.txt, For2.txt, For3.txt

Readings: Chap. 4

Char Lecture

For loops

10 2/21

Using Char: char_entry, Char.txt, CharInput.txt, directions_using_if, directions_using_switch

Using length() to get the number of characters in the string: char using length

Shortcut operators: pre_post increment , Shortcut_operators

For loops: For1.txt, For2.txt, For3.txt

 

 

 

11 2/26

Using Counter controlled loops: String example, Sqaure numbers_ loop,

Using Sentinel value to control loops: Average , MaxNumber

While and for loops using numbers:

while loops with numbers
,for loops with numbers , Sqaure numbers_ loop , product_loop

 

Sentinels loops  

While loops  

 

12 2/28

Review While loops using numbers:

while loops with numbers

Manipulating String and Char using loops:

For loops examples (char): For loop using char , For loop using char example 2 , Alphabet.txt

 

 

 

 

 

13 3/4

Midterm #1 Review

 
14 3/6 Midterm # 1 Exam (20% of course grade)  
15 3/11

Using Counter controlled loops: String example, Sqaure numbers_ loop,

Using Sentinel value to control loops: Average , MaxNumber

More While Loops with letters: while loop to count # of vowels, while to count # of commas and spaces

 

 
16 3/13

More loop examples, do while loops

Do while example: DoWhileTest.txt, do-while example #2.

Using break and continue in loops: Using break and continue in a loop

Casting IntLong.txt, Casting.txt, InaccurateDouble.txt 
See (Mathematical operators lecture) for more information on casting

String comparisons:
http://www.leepoint.net/notesjava/data/strings/12stringcomparison.html

 

  Do while
Spring Break 3/17 - 3/21  
17 3/25

Nested Loops examples: Nested loop using seconds and minutes, sec. min. and hours and days in one week ,

Producing 2 D shapes using nested loops:
Square_example, Rectangle
Triangles: right triangle1, triangle2, triangle3

 

 

Nested loops

 

 

18 3/27

More nested loops:

Rug Art Example: viewing regular patterns in kilims from Iran and Bulgaria from Kilims: A Buyer's Guide by Lee Allane

More nested loops examples using rugs pattern: pretty rug example 1, puzzle

More Nested loops examples:
multipication table1, Nested loops using multipication table2

 

 

 

19 4/1

Methods


Readings: Chap. 5

Methods in Java

20 4/3

More work with Methods:
Square, sqrt

Squares, max method with two parameters

 

 




 

 

 

21 4/8

Methods: Generating Random numbers:

Example of Math class Methods , Raise_to_Power

Example of Math class Methods

More example on generating random numbers with methods:

Generating Random numbers:


Generating random numbers and a range of random numbers
Generating random characters  and randomly rolling a die

NoParameters, ReturnVoid

example on generating random numbers with methods: random word(5 small letters)

Random method to generate different ranges of random numbers, Random method (interactive and effecient), random word(5 small letters)

 

Generating random numbers lecture: Random
22 4/10

More Methods:

 

 

 
23 4/15

Midterm # 2 Review



 
22 4/17

Midterm # 2 Exam (20% of course grade)



23 4/22

  Arrays: arrays example 1, arrays example 2 , arrays example 3 ,arrays example 4 , arrays example 5 , arrays example 6, arrays example 7, arrays example 8 , arrays example 9 , arrays example 10

Readings: Chap. 6
Arrays lecture

24 4/24

 Methods with arrays: PassArray , TestPassArray ,Deviation ,

Fun examples:
http://www.chalcedony.com/java/code/prog10.1/listing1.html

 

 

 
25 4/29

 Methods with arrays:

Copy array (refrence) , Copy array elements using a loop , Copy array elements using System.copyarray method

 


26 5/1

Applets (not on final): applets examples & injstructions

Final review; last day of class

Applets lecture