About these programming exercises

This site contains Java programming and computer science exercises with solutions. To see the solution for an exercises please follow the link to the Javadoc at the and of the exercise's text.

These exercises are designed for an introductional course into computer science with Java as the first programming language. Some of them have been former used as pratical assignments for my lecture. They cover basic algorithm design and the fundamental concepts of Java (without inheritance, abstract classes, and inner classes). These exercises are not suitable to learn about Java libraries and APIs like GUI developement with Swing, server side Java or other special Java technologies. To learn about Java technologies, have a look at the Java tutorials at Sun.

You can download all solutions to the Java programming exercises as a compressed zip archive. The source of the Java classes is UTF-8 encoded. Most Java classes can be compiled with Java 1.4, some need Java 1.5 or Java 1.6. Use the newest Java version if possible. You need JUnit to compile the Java test classes.

It is possible to use most of the programming exercises for other programming languages like C# or C++ as well.

Organization of the Java programming exercises

The exercises are given in chronological order and by topic. Furthermore, I estimated the degree of difficulty of each Java programming exercise.

List of all Java exercises

New exercises can be found at the start of the list. I am currently translating my german version of the Java exercises to English.

Java exercises of September 2007

Java exercises of August 2007

Java exercises of July 2007

Java exercises of June 2007