4.4 Week 4 -- Unicode, Floating Point, ...4 Operator Precedence and Associativity4.2 Week 2 - A simple program4.3 Week 3 - Strings, Comments, & Statements

4.3 Week 3 - Strings, Comments, & Statements

4.3.1 Reading and Web Sites

  1. Finish reading van der Linden Chapter 3, Explanation of a Simple Program
  2. Read van der Linden Chapter 4, Identifiers, Keywords, and Types
  3. Start on van der Linden Chapter 5, Names, Arrays, Operators, and Accuracy
  4. Run the sample program p66 in van der Linden.

4.3.2 Notes

4.3.3 Lab Assignment - Exception and Integer overflow

Modify your second program so it after it prints your name and the current date it:
  1. enters a for loop from -3 to +3 and prints out 10 divided by the loop counter. Catch the ArithmeticException and print out "Divide by zero"
  2. A section of code that demonstrates that two's complement overflow fails to cause an exception
Turn in a copy of your program and an example run.

4.3.4 Lab Assignment - "rewrite" and restructure the example program

Turn in a copy of your program and an show me a sample run.


Instructor: ltaber@pima.edu ** My new Home at GeoApps in Tucson ** The Pima College Site

4.4 Week 4 -- Unicode, Floating Point, ...4 Operator Precedence and Associativity4.2 Week 2 - A simple program4.3 Week 3 - Strings, Comments, & Statements