|8:30 - 9:00||Breakfast/Welcome|
|9:00 - 10:30||Arrays, ArrayLists, Exam Questions|
|10:30 - 11:45||Programming Examples: IO, Files, Arrays|
|11:45 - 12:30||Lunch|
|12:30 - 2:00||Event Programming Overview/Examples|
|2:00 - 2:30||Discussion of JETT Future|
|2:30 - 3:30||Model, View, Controller (MVC)|
java.util.ArrayListclass. This will also lead into discussions of interfaces, inheritance, the Java subset, and related issues.
2003 AP exam questions in Java
standardCountso that it calculates how many 1-letter words, 2-letter words, ... 15-letter words there are. Print a table of occurrences, similar to the table printed in DiceAnalyzer.java programmer.
You'll need to create an array as an instance field/data member,
initialize it, update the counts in method
and then add a new method (and call it) to print the contents of the
array. Test the program using
indexOfvery helpful, see the API (via JCreator). Don't print the contents of the ArrayList when done, but do print (using a method
reportStats) the number of words stored. Test the program using
TreeSet(also from java.util). You'll need to use just the four statements below, but you'll need to put them in the proper location. See how much longer/shorter your program takes to run than when using the ArrayList version.
TreeSet mySet; mySet = new TreeSet(); mySet.add(word); System.out.println("# unique words = " + mySet.size());
http://the browser won't load a page correctly. Fix the program so that if a user-entered URL doesn't begin witht he proper prefix, then it is added to the URL before loading.
(hint: One simple idea is to use an ArrayList of URLs that have been visited and a current index into this list. Going back/next decrements or increments, respectively, the index.)
Copy the files to a new folder, then modify only the model so that a game of light-out is played. We'll demo lights out so you can see how it works.