CS151 Computer Science I
Lecture demos
- Week 2 lectures: The ADD operator example.
- Week 2 lectures: The Arithmetic example.
- Week 3 lectures: The numeric input example.
- Week 3 lectures: Inputing floating point values example.
- Week 3 lectures: Example on coversions between data types (using casting).
- Week 4 lectures: The Right Triangle example (if - else statement).
- Week 4 lectures: The Switch statement example.
- Week 5 lectures: Computing factors example (while statement).
- Week 6 lectures: Find avarage and highest grades example (while statement).
- Week 6 lectures: How long money should stay in a bank example (while statement).
- Week 6 lectures: A nested loop example.
- Week 7 lectures: Example on for
loops and switch statement.
- Week 7 lectures: While loops vs do loops vs for loops (a comparison example).
- Week 8 lectures: The StringTokenizer example version 1, and version 2.
- Week 8 lectures: Flipping a coin example (the Random class example).
- Week 9 lectures: Rolling a dice example (the Random class example).
- Week 9 lectures: The date verification example problem description and pseudo code and the code.
- Week 9 lectures: The parameter passing example.
- Week 10 lectures: The Triangle problem from homework 4: More than just a hint.
- Week 10 lectures: Creating your own classes, Selecting a computer example.
- Week 10 lectures: The CD example from Lewis & Loftus, previous edition.
- Week 10 lectures: The Circle example.
- Week 10 lectures: The Rectangles example
- Week 11 lectures: The Bank example, which uses a static method.
- Week 11 lectures: The URL example, using the StringTokenizer class.
- Week 11 lectures: The Casino example illustrating method overloading.
- Week 11 lectures: The Sphere example illustrating aggregation and nested classes.
- Week 12 lectures: An example using a text file version 1, version 2, version 3, version 4, and the data file that goes with them.
- Week 12 lectures: The Salary Update example, and the data file that it uses.
- Week 12 lectures: An array example using a text file find the largest element and the data file that goes with it.
- Week 12 lectures: An array example find the avarage.
- Week 13 lectures: Array of counters example - the program and the data file that goes with it.
- Week 13 lectures: Command line arguments example.
- Week 13 lectures: The Monthly Sales example.
- Week 13 lectures: The Membership example.
- Week 14 lectures: An array of objects example.
- Week 14 lectures: Representation of multidimentional arrays example 1, example 2, example 3.
- Week 14 lectures: Vector with different data types example
- Week 14 lectures: StringBuffer class example
- Week 15 lectures: Inheritance example.
- Week 15 lectures: The inheritance example modified.
- Week 15 lectures: The Bank account example modified.
- Week 15 lectures: Inheritance example demonstrating overriding a supperclass method.
- Week 15 lectures: The Bank account example extended.
Assignments and announcements
- Get started and test your jdk installation by compiling and
running the following application programs: program 1,
program 2,
and the following Java
applet.
-
Homework 1.
Deadline: September 16/17, 2009.
-
Homework 2.
Deadline: September 28/29, 2009.
- !!! Section 01: No class on Thursday, October 1 !!!
-
Homework 3.
Deadlines: October 14 (Sections 02 and 70) and October 15 (Section 01)
- !!! Section 01 : Test 1 will be held on October 20, 2009 !!!
- !!! Section 02 : Test 1 will be held on October 16 (50 min) and Oct 19 (25 min) , 2009 !!!
- !!! Section 70 : Test 1 will be held on October 19, 2009 !!!
-
Homework 4.
Deadline: November 9/10, 2009.
- !!! Section 01 : Test 2 will be held on November 17, 2009 !!!
- !!! Section 02 : Test 2 will be held on November 13 (50 min) and November 16 (25 min) , 2009 !!!
- !!! Section 70 : Test 2 will be held on November 16, 2009 !!!
-
Homework 5.
Deadline: November 23/24, 2009. Extended deadline: November 30/ December 1, 2009.
-
Homework 6.
Deadline: December 9/10, 2009.
- ********************************************************************
- !!! Section 02 : Wednesday, December 2, class is CANCELLED. However, I'll be holding
my CS 151 70 class (Wednesday, December 2, at 5:15 MS 223) and I strongly advice everyone
from Section 02 to come to that class or to my CS 151 01 class (Thirsday, December 3, at
12:30 MS 214). I'll be covering ARRAYS of OBJECTS and will go over HW 6, project 2.
Also, I will have additional office hours just before my Wednesday evening class, and regular
office hours after the class.
- *********************************************************************
- !!! Section 02: Wednesday, December 9, class is CANCELLED because of the snow. There will
be TAKE-HOME quiz for 4 points to be announced on Friday here on my Web site which will be
due Wednesday, December 16 at 8:00 a.m. I'll see you then for our final exam. Submit homework 6 and the quiz on Wednesday, December 16, WITHOUT
flash drives. I'll return homework 5 at that time.
- **********************************************************************
-
Take-home quiz.
Deadline: submit with the final exam.
Lab exercises
- Lab 1 problems.
- Pool program, version 1.
- Pool program, version 2.
- Yard program,version 1.
- Yard program,version 2.
- Lab 2 problems.
- Lab 2, problem 1.
- Lab 2, problem 2.
- Lab 2, problem 3.
- Lab 2, problem 4.
- Lab 2, problem 4 revised.
- Lab 3 problems.
- Lab 3, problem 1.
- Hints for Lab 3, problem 2:
(1) string input utilizing standard Java input,
and
(2) string input utilizing a method from the String class.
The complete program will be posted after discussing student versions
in class.
- Lab 3, problem 2, version 1.
- Lab 3, problem 2, version 2.
- Lab 3, problem 3.
- Lab 3, problem 4, version 1.
- Lab 3, problem 4, version 2.
- Lab 3, problem 5.
- Lab 3 problem 6.
Return to Zlatareva's Home Page