Java Demos

Here are several Java demos, as zip files (for BlueJ/IntelliJ projects) or as .java files, or both

arraylisttest: Lets you peek, with the inspector, at the underlying ArrayList space allocation (BlueJ, IntelliJ)

ratio: Bailey's Ratio class (also and and also ratio.cpp) (BlueJ, IntelliJ)

linkedlist: A simple linked-list class, with and (BlueJ, IntelliJ)

recursion1: A class to illustrate recursion for and (BlueJ, IntelliJ)

stampchange: a problem hard to solve without recursion; also an answercache example. (BlueJ, IntelliJ)

binsearch: A demo of binary search, looking for a particular case. (BlueJ, IntelliJ)

hash: A demo of hashing, including,,, Also and (BlueJ, IntelliJ)

baileysorting: includes most of the sorting methods of Bailey Chapter 6, in (BlueJ, IntelliJ)

expressions: a recursive program for evaluating numeric expressions. (BlueJ, IntelliJ)

TList: a template ArrayList-like class. (BlueJ, IntelliJ)

simpletrees: some simple binary trees of Strings and integers. (BlueJ, IntelliJ)

traversers: some simple and not-so-simple ways of traversing a binary tree. (BlueJ, IntelliJ)

poly: a simple example of polymorphism. (BlueJ, IntelliJ)

compiler: a simple [!] recursive-descent compiler for the (demo) language miniJava. (BlueJ, IntelliJ)